Click here to Skip to main content
15,916,188 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: How to Train Your Programmer Pin
Manfred Rudolf Bihy3-Jan-12 2:27
professionalManfred Rudolf Bihy3-Jan-12 2:27 
GeneralRe: How to Train Your Programmer Pin
bosedk3-Jan-12 2:50
bosedk3-Jan-12 2:50 
GeneralRe: How to Train Your Programmer Pin
0bx3-Jan-12 4:18
0bx3-Jan-12 4:18 
GeneralRe: How to Train Your Programmer Pin
Lutosław3-Jan-12 10:38
Lutosław3-Jan-12 10:38 
GeneralRe: How to Train Your Programmer Pin
RobCroll3-Jan-12 14:36
RobCroll3-Jan-12 14:36 
GeneralRe: How to Train Your Programmer Pin
Nagy Vilmos3-Jan-12 22:57
professionalNagy Vilmos3-Jan-12 22:57 
GeneralRe: How to Train Your Programmer Pin
Bernhard Hiller3-Jan-12 23:19
Bernhard Hiller3-Jan-12 23:19 
GeneralRe: How to Train Your Programmer Pin
Jeroen De Dauw4-Jan-12 0:34
Jeroen De Dauw4-Jan-12 0:34 
GeneralRe: How to Train Your Programmer Pin
johannesnestler11-Jan-12 3:37
johannesnestler11-Jan-12 3:37 
GeneralGem code Pin
zenwalker198528-Dec-11 3:00
zenwalker198528-Dec-11 3:00 
GeneralRe: Gem code Pin
Paladin200028-Dec-11 4:09
Paladin200028-Dec-11 4:09 
GeneralRe: Gem code Pin
zenwalker198528-Dec-11 15:02
zenwalker198528-Dec-11 15:02 
GeneralRe: Gem code Pin
ekolis29-Dec-11 11:52
ekolis29-Dec-11 11:52 
GeneralRe: Gem code Pin
zenwalker198529-Dec-11 18:37
zenwalker198529-Dec-11 18:37 
GeneralRe: Gem code Pin
krumia14-Feb-12 19:20
krumia14-Feb-12 19:20 
GeneralCool bitwise trick page Pin
Lutosław28-Dec-11 0:46
Lutosław28-Dec-11 0:46 
GeneralRe: Cool bitwise trick page Pin
harold aptroot28-Dec-11 1:35
harold aptroot28-Dec-11 1:35 
GeneralRe: Cool bitwise trick page Pin
Rajesh Anuhya30-Dec-11 2:10
professionalRajesh Anuhya30-Dec-11 2:10 
GeneralTest-driven voodoo magic Pin
jesarg27-Dec-11 7:09
jesarg27-Dec-11 7:09 
JokeRe: Test-driven voodoo magic Pin
Paladin200027-Dec-11 7:55
Paladin200027-Dec-11 7:55 
GeneralRe: Test-driven voodoo magic Pin
Slacker00727-Dec-11 8:02
professionalSlacker00727-Dec-11 8:02 
GeneralRe: Test-driven voodoo magic PinPopular
OriginalGriff27-Dec-11 8:28
mveOriginalGriff27-Dec-11 8:28 
GeneralRe: Test-driven voodoo magic Pin
Gary R. Wheeler27-Dec-11 9:44
Gary R. Wheeler27-Dec-11 9:44 
GeneralRe: Test-driven voodoo magic PinPopular
CDP180228-Dec-11 11:57
CDP180228-Dec-11 11:57 
I only know a lazy cargo cult Java team. They turn everything into a hollow useless ritual that's not worth the work you put into it. They also wanted me to write unit tests. The problem was that they were far too agile to provide any specifications about what might be correct and what is not correct. To be precise, they were not able to come up with any specifications at all.

So I was creative and tested everything that might possibly go wrong that came to my mind. The result was that practically all the tests failed, once I checked them in. Oh horror! The build ritual failed! And how did they 'fix' it? No, not by looking at the tests and sorting out where the tests might be too strict or where they might be pointing out some issues. They simply commented out all the code in the tests and checked them in again.

Now the build ritual does not fail anymore and the unit test ritual also has been sucessfully completed. Bravo! Now you can go back to sleep and hold up your build reports with 100% sucessful unit tests when somebody asks.
And from the clouds a mighty voice spoke:
"Smile and be happy, for it could come worse!"

And I smiled and was happy
And it came worse.



GeneralRe: Test-driven voodoo magic Pin
Bernhard Hiller28-Dec-11 20:20
Bernhard Hiller28-Dec-11 20:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.