Maybe they'd been studying The Art of Computer Programming, in which a byte is 6 bits (when it's a binary byte, as opposed to a decimal byte!) and got it slightly wring.
Best posts made by token_woman
-
RE: Overheard at Work
-
RE: Don't test, it gets in the way of code coverage
@Justice said:
So they start with unjustified, pointless dogma and then foolishly circumvent it by
selling indulgencesleaving out assertions.This sounds like somebody tried to enforce a test-driven process on a cowboy culture, and the barbarians played along but really just kept doing things their own way.
Obviously given what I said about TDD I personally disagree with the remark about pointless dogma.
But I have no issue with anyone choosing not to go the test-driven way.
What bugs the bejeezus out of me is that they spend time writing all this "coverage" and not spend the extra few minutes to make it actually do something. Might as well ya, know, Since it's THERE...??
(edited to hand-code line breaks in)
-
RE: Don't test, it gets in the way of code coverage
@blakeyrat said:
Shocking news: horses led to water can not be forced to drink!
Sure, but if you don't want to drink, why go to the water?
If you don't want to really do unit tests why start a company working exclusively on a platform that forces you to write them?
And why TF would you employ someone with "Looking to work in a test driven environment" at the top of their resume - wouldn't "They will discover the sham and leave" suggest itself at some point in the hiring procedure?
-
Don't test, it gets in the way of code coverage
I've just started with a company that develops bespoke apps on the salesforce platform.
I never expected it would be my vocation in life, to put it mildly, but one thing did attract me to it. I'm into test driven development and in salesforce test coverage is enforced - it's a managed platform, and you are prevented from pushing any code to production that has less than 75% coverage. Great, I thought, no more having to persuade colleagues of the value of testing, etc. .....
Then, the other day, my boss asked me to look at an app he'd written. It had nearly 75% coverage and he wanted me to add a couple more tests. Well I started looking through the existing tests to see how he wanted them done......
They had no assertions in them. They couldn't fail. They "covered" the code, by simply running the code, whether it worked or not.
I assumed the boss was the usual non-coding coder you get for an MD in these little companies and whispered to the guy next to me that I had come across this abomination and asked him how I should tactfully correct it.
"Oh no," he said, "It's supposed to be like that. We all do it like that here."
"Well", I said, "I'll let it go in his code I suppose, but when write tests myself I think I would rather put the assertions in."
"I wouldn't do that," he said. "You need to spend your time efficiently getting the code coverage up. Don't waste time on assertions. Do you realise assertions add nothing to the coverage figure?"