Remix.run Logo
simonw 5 hours ago

Out of interest, what language ecosystems do you tend to work in?

My guess is that some languages - like Go - have a more robust testing culture than other languages like PHP.

jama211 4 hours ago | parent [-]

Not who you asked but I think it comes down to risk/reward. The consequences of some user finding a big in most websites is low, compared to the risk of an astronaut finding a bug the hard way whilst attempting re-entry.

There is genuinely a reasonable and rational argument to “testing requires more effort than fixing the issues as users find them” if the consequences are low. See video games being notorious for this.

So, industry is more important than language I’d say.

simonw 4 hours ago | parent [-]

I don't see testing as a quality thing any more, I see it as a developer productivity thing.

If my project has tests I can work so much faster on it, because I can confidently add tests and refactor and know that I didn't break existing functionality.

You gotta pay that initial cost to to get the framework in place though. That takes early discipline.

GrumpyYoungMan 38 minutes ago | parent | next [-]

Developer testing is checking whether the code does what the developer themself thinks it should. QA testing is checking whether the code does what the customers / users / rest of the world thinks it should.

smackeyacky an hour ago | parent | prev [-]

It’s a lot faster and easier than it used to be. Things like xUnit in the .net world make setting up tests friction free to the point where I question a codebase that doesn’t have some kind of basic unit tests. It doesn’t make mock testing or integration testing easier but I would argue if you know the base code and logic is sound those tests are less relevant.

One thing I found is that if testing is easy, your code structure does change a bit to aid with a “test first” approach and I don’t hate it. I thought it made me slower but it doesn’t, it ensures that when all the ground work is finished, the gnarly part of wiring everything up goes much faster.

simonw an hour ago | parent [-]

Yeah I've found the same, having good test discipline influences my code design in a positive way because code that's easier to test is also code that's easier to integrate and understand.