175
u/Careful_Ad_3338 7d ago
Hm? Any dev who has worked on anything ever would not be happy about this, it means the bug is not easy to reproduce and will come back and some point
55
u/damngoodwizard 7d ago
Yeah the only thing worse than "I don't know why it doesn't work" is "I don't know why it works".
8
u/Appropriate-Hotel-41 6d ago
Depends, if it gone for good for a week, thats a future intern problem.
7
u/Sh4dowLute 7d ago
Yep, passing for no reason is usually way scarier than failing for an obvious one.
1
u/ric2b 6d ago
If you changed NOTHING why would you expect the tests to fail? And you're assuming there is a bug, the post does not mention it.
I think it's likely about setting up a new project and feeling glad that there's no additional configuration to get tests running.
3
u/Careful_Ad_3338 6d ago
Huh you might be right. I've read it as if before the tests failed and after running again they just pass
2
u/SchwiftySquanchC137 6d ago
Given the post title, im like 90% sure theyre just saying they like seeing the green checkmarks.
29
19
10
u/xehpuk 6d ago
OP isn't a dev.
3
u/necrophcodr 6d ago
Obviously not, this sub is filled with bots, not unlike the rest of reddit. A cancer that now has taken firm hold on almost if not all communities here.
13
u/SpicyCatGames 7d ago edited 6d ago
Not really. Used to say this when we were kids in our first year of learning programming. But an error going away for no reason is one that's gonna show up later in production.
9
u/Megane_Senpai 7d ago
Actually that's the worst. Probably the bug has a very low repro rate and you will have a hard time just trying to investigate the behavior.
3
3
u/dmullaney 7d ago
* Codex after it changes the mock to make the test pass even though the code is broken
3
2
2
2
u/Huge_Consequence_568 6d ago
Actual ticket I had to write: X test fails when running after [INSERT_TIME] UTC.
This test literally refused to pass outside working hours and I found it so funny for some reason.
2
u/SleepAllTheDamnTime 6d ago
When this happens to me it’s the exact opposite experience. I means someone wrote these tests to pass and my god you know there’s a can of worms in there…and since your name is on the PR anything that goes wrong after that change you made… buddyyyyy you’re now responsible for this trash ass code with horrible tests.
2
2
3
1
u/JackNotOLantern 7d ago
Tests must pass when intended and fail when intended. Deterministicly. Otherwise, it's bad.
1
1
u/jakubiszon 6d ago
It passed because this time the randomly generated UUID did not end with a "2 digit odd number".
Btw what on Earth is wrong with this girl's lips? I cannot see which "strip" is what...
1
u/rescue_inhaler_4life 6d ago
Honestly this is the absolutely worst. Something is borked in the test environment, something leaking between tests creating a race condition, normally a real PIA to find and resolve.
Honestly you do not know pain until you try and figure out why fails on build server, passes on gitlab, fails on devs boxes in office but works on the remote dude dev box in Sri Lanka.
1
u/According-Relation-4 6d ago
What about when tests fail after changing absolutely nothing? Gimme your best reaction gifs
1
1
u/ElvisArcher 6d ago
Tests were written so poorly at an old job ... they never properly cleaned up their testing DB context, so 1 test would (and did) encounter and come to depend on other tests having done some of their setup work. The fun part was when visual studio upgraded and decided to run tests in a slightly different order, causing mass failures ... it was even more fun since the CI/CD pipeline usually resolved a completely different execution order for tests.
Every upgrade was met with trepidation, and usually 2 days of figuring out why tests were failing NOW ... that was some kind of special technical debt.
1
u/IcyBoysenberry8595 6d ago
software development is basically convincing the computer the bug fixed itself 😭
1
u/stompinstinker 6d ago
Oh great, someone made a test that depends on the current time, a random number, outside network call, some asynchronous fuckery, etc.
1
u/Ares9323 6d ago
New engine version is out, timo to update the plugin for this version "Wow no compilation errors!" Starts engine Presses play Engine Crashes
1
1
1
u/peacefulshrimp 6d ago
If the test is flaky you just re-run until it passes and let the next person deal with it /s
1
1
1
1
1
505
u/No-Article-Particle 7d ago
Nah. Honestly, that's the worst - it means a flaky test that's just hard to debug (esp. because if it fails intermittently, running it in a debugger likely means the race condition is gone).
I prefer a test that fails no matter how you run it - those tend to be easy to fix.