this post was submitted on 02 Nov 2023
1406 points (98.5% liked)

Programmer Humor

31998 readers
813 users here now

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

Rules:

founded 5 years ago
MODERATORS
 
(page 2) 32 comments
sorted by: hot top controversial new old
[–] [email protected] 3 points 10 months ago

Lmao, I just had something similar

[–] [email protected] 2 points 10 months ago

This is why you write the tests first before the actual code.

[–] [email protected] 1 points 10 months ago (1 children)

Meaning your tests where to complex.

[–] [email protected] 1 points 10 months ago

I always name my tests too complex 🥲.

[–] [email protected] 1 points 10 months ago (1 children)

I've seen some interesting thoughts on TDD with fail, pass, refactor assumptions. I'm curious if anyone here is writing functional code in order to then make a failing functional test pass i.e. BDD / ATDD. This follows similar logic without the refactor assumption. I've seen strong opinions on every side as far as this is concerned. On a team with Dev and QA competencies, I've heard a number of devs glad to get QA out of the bottleneck and put their knowledge to better use.

load more comments (1 replies)
[–] [email protected] -2 points 10 months ago

ChatGPT go brrrrrr

[–] [email protected] -4 points 10 months ago (7 children)

If you use your type system to make invalid states impossible to represent & your functions are pure, there less—maybe nothing—to test, which will save you from this scenario.

load more comments (7 replies)
load more comments
view more: ‹ prev next ›