this post was submitted on 16 Sep 2024
136 points (95.9% liked)

Programmer Humor

32061 readers
1029 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 

top 11 comments
sorted by: hot top controversial new old
[–] Dunstabzugshaubitze@feddit.org 34 points 4 days ago

good Tester.

If something stupid can be done, it will be done.

[–] hellfire103@lemmy.ca 17 points 4 days ago

I've seen this enough times that I laughed without watching it. Funny stuff.

[–] Lussy@hexbear.net 20 points 4 days ago (1 children)
[–] cmgvd3lw@discuss.tchncs.de 11 points 4 days ago

Name is Alison Burke.

[–] deadbeef79000@lemmy.nz 15 points 4 days ago* (last edited 4 days ago) (1 children)

This is why it's important to have tests that assert a system's failure modes too.

shouldFitTriangleInTriangleHole()

shouldNotFitTriangleInAnyOtherHoles()

Bonus points for just parameterizing it.

[–] elvith@feddit.org 3 points 4 days ago
 assert triangleObject.shouldFitInHole(triangleHole) == true

assert triangleObject.shouldFitInHole(squareHole) == false
[–] pastermil@sh.itjust.works 10 points 4 days ago

Anything can be a square hole if you're brave enough.

[–] Dirk@lemmy.ml 10 points 4 days ago

If a function takes all types of variables it's your own fault!

[–] propter_hog@hexbear.net 9 points 4 days ago

Testers are a godsend

[–] reverendz@lemmygrad.ml 3 points 4 days ago (1 children)

Poor development! If something can be done, people will do it.

Best way is to not allow it and provide no feedback.

[–] BearOfaTime@lemm.ee 4 points 4 days ago

Wait, provide no feedback?