Inb4 the agents change the tests to pass the CI.
Programmer Humor
Welcome to Programmer Humor!
This is a place where you can post jokes, memes, humor, etc. related to programming!
For sharing awful code theres also Programming Horror.
Rules
- Keep content in english
- No advertisements
- Posts must be related to programming or programmer topics
literally seen an agent do a: "oh now the tests aren't passing" deletes all tests in the file
Or my Claude favorite, “oh you’re right? I did blow past that restraint and did something I was not supposed to, sooooorrrrreyyyyy”
assert(true);
assert(true);
assert(true);
assert(true);
assert(true);
"I stopped reading code because I was too busy writing a gauntlet of unit tests"
Sounds like 100x productivity to me.
There is a 0% chance he wrote all those tests himself anyway
Sounds like a cryptobro peddling some shitcoin claiming that it's impossible to get scammed because "code is law" four seconds before the coin's value drops to zero.
Been coding for about 30 years now, am I the only one who still LIKES to code? Who still LIKES to try writing a new approach to something, watching it fail, figuring out what went wrong, taking notes, learning from mistakes, and noticing improvements in their own code? Cuz it's starting to feel like it. Web development already lost me with the culture of "glue a bunch of bulky shit together that you didn't write and call yourself a 'dev' to the ladies" but this AI shit is getting absurd. And it doesn't even work! Look at how shitty all the operating systems are getting. Look at all the total slop on the app stores. It's depressing as hell.
I love coding and learning new languages. I'd rather move to another industry than reviewing vibe coded crap all day long.
I'm significantly older than you. I started coding in the late 60's
Yeah, appeal to tangentially related experience, age and arrogance aren't a way to inspire confidence in your work.
We live in the perfect times to display that experience, age and arrogance haven't been working in almost any field, from politics to LLM development. We've yet to witness any system that operates well, while also eliminating human oversight. It doesn't matter the guard rails you put in place. They're only as strong as your personal ability to evaluate your own product, which itself is a conflict of interest.
Edit: Also, you can't use your own credentials to assert the integrity of work you aren't even actually doing.
Not to be too flippant, but:
Boomers gonna boom.
They literally can't help themselves, they're egomaniacal narcissists.
The rare ones that aren't that way can truly be awesome sources of perspective... but goddamnit so many of completely insufferable babies.
Is this a joke?
No. Everyone in tech that's not a mediocre tech bro has known Uncle Bob is an overrated quack for a long time.

He fails to mention that he has AI also generate and do all of those tests, which means, A) he has no quality supervision over his quality supervision. Speaking from experience, AI can and will break a test in order to pass it rather than fixing the code if it randomly decides to. It is not always reliable and does not have even the baseline of good sense you would expect a brand new junior dev to have. And B) he's probably spending 3 times as much on tokens used for generating and running tests than he is already using on code generation. That's only going to be sustainable while these tokens remain cheap, which won't be for much longer, my guy.
Also it is always fun when someone asks you basic questions about your code and you have to admit complete and total ignorance because you neither wrote nor read a single line of it. How are you going to sell confidence in your black box that even you haven't peeked inside?
The D Language Foundation tried to incorporate LLMs in the unittests, and they created something akin to assert(5 + (funcToTest(846) * 0) == 5) early on, now they want to use it to rewrite the standard library from scratch, because "it has become better since".
The other day I had Claude write some code that failed a unit test. It was failing at a step that ran assertEquals(actualMap, expectedMap);. The reason it was failing was because one of the values in the map, a UUID, is automatically generated in the code. In the test, it has been hard coded.
Anyone with any sense would know you need to handle that misalignment. Omit that field from the match assertion? Set that UUID based on the generated value instead of hardcoding it? Anything like that would work just fine.
But Claud's solution was to change that assertion to assertTrue("The actualMap and expectedMap will never be equal because the values of ID will never match");. So the test always passes and it explicitly notes that they will not match. I would have fired a Junior Dev on the spot for writing that solution.
None of this actually proves that they aren't writing slop. It just proves that the slop that they've written passes your tests.
So he does more work so he can do less work? Am I reading that right?
"I use a hammer"
"Well, I use a device that applies an enormous amount of pressure constrained to a very particular point in space"
"How much does your device cost?"
"$200/mo and the company loses money every time I swing it. You?"
"$12 and I've had this thing for 20 years."
i wrote 4000 lines of code to make sure the AI generated 100 lines of code correctly.
What he is describing is what you are supposed to do for human written code also.
I've actually found a lot of success with the opposite where I write the code and AI writes the unittests. I would have otherwise written a few unit tests, but AI makes typically 20x that many. Since my code is already documented, it can get lots of good context. I typically instruct it to check the branch's diff relative to main and test only those changes. I might skim them over, delete some that don't make sense in context and would never pass, and update one or two. Typically after a few rounds of iteration, I have tons of tests I would never have written on my own, and a human-made feature.
I see all the tests are passing on this PR, so I won’t even review the code. LGTM.
🙄😖
Isn't this just the natural evolution of TDD? Write tests, pass them, don't care about how garbage the code is to make them pass
this guy has always struck me as a shitty coder. His "clean code" is the ugliest shit i ever saw. This confirms it.
You should definitely read the code, but the strict acceptance for generated code is a good starting place.
Uncle Bob has always been a hack whose advice made code less maintainable.
The tests that the AI wrote? :D
Except LLM agents are known to do weird things to succeed. I have heard of an LLM agent working with automated theorem proving languages using stuff similar to is_prime(x): return True to get the proof it was asked to. Now embed this in a 20000 line code full of such functions, good luck. They have their use but it is not this. And this is especially bad to hear from someone who used to claim that having functions with more than six variables is bad design because it is hard to maintain. A software fully written by an LLM is the epitome of unmaintainability. LLMs are productivity enhancers, information retrievers, nice debuggers and good to discuss questions with to see if there is an angle you miss. That is all this if you can put aside all the ethical concerns related to them ofcourse. But they are not automated software coders.
Sure this is bad, but is it really "becoming even worse" after he already publicly declared support for Trump?
Translates to:
"I created this (unit) test that tests code that does not exist yet..."
Alright AI bro keep your copium...
So in other words he spends weeks to write extra tests so that the agent can save him days of coding.
I saw an argument today that was presented in a very rage inducing way but in the end I had to agree that it wasn't the worst of takes: your code won't get any worse just because you let the infinite slop machine have a go at trying to find problems in it.
There could be a million other reasons not to use AI but if your only argument against it is that you don't trust the code written by AI to be good enough to be included in your code base, then you're just not thinking about every way that the clankers can be put to work.
I'm not arguing in favor of using AI by bringing this up. If you're morally opposed to it then this point makes absolutely no difference.
AI for code review is, I am pained to admit, a genuinely extremely pleasant addition to my workflow - it inherently is a process that involves humans checking it's work, and that kind of pattern recognition is one of the things that AI models are actually proficient at. It's for sure not bullet proof and it's pretty rare for it to catch something real that I wasn't already aware of, but it takes no time, doesn't touch my code directly and does pick up tiny errors like fenceposts or bad typing that make up the majority of my time when I'm running things down manually.