4 ms·
Is this about the sad state of test frameworks or about the sad state of C test frameworks? There's a reference to JUnit I don't understand. Junit provides the
by alanfranzoni 10y ago
Is this about the sad state of test frameworks or about the sad state of C test frameworks? There's a reference to JUnit I don't understand. Junit provides the ability to aggregate tests in suites (strict hierarchies wtf?).
Benchmark may be a different concern.. I know you can do something with rules but it may require more time to set up.
By the way: creating a small, self developed tool that just does what you need is sometimes a good idea, but it doesn't mean everything else is shit. Any library serving a large user base will serve somebody better than others.
- NickNameNick 10y agoI'm not sure if it's what the author was getting at, but you can't order test execution in junit, so you can't chain together integration tests. Of course, that's why you use other tools like TestNG. Unit tests aren't _units_ if they're interdependent. edit Looks like the author was trying to execute multiple overlapping test suites. Haven't tried that.
- smoyer 10y agoJUnit 5 [1], which is currently under development will include the ability to control test order. The whole framework was redesigned with a consistent model for extending almost all aspects of the system. [1] http://junit.org/junit5/ http://junit.org/junit5/
- jacques_chester 10y agoI looked at JUnit 5 recently and it's super super promising. The website design does rather give the impression that it's done. I know that if I read the text, I learn that it's not, but my brain categorises those paras as marketing fluff and ignores them. But it looks very much like what I want from Java testing. My views have, admittedly, been warped by RSpec and Jasmine.
- emmab 10y agoWould JUnit categories work? https://github.com/junit-team/junit4/wiki/categories https://github.com/junit-team/junit4/wiki/categories
- codr4life 10y agoThe only thing you can say in JUnit is that this test is part of that suite. My tests have several aspects that I'm interesting in using for triggering. Sometimes I want to run all DB tests, regardless of which suite they're in. That's what I mean by strict hierarchies. Part of the point I'm trying to make here is that once you've written a couple of test suites, you probably have a pretty good idea what tools you would prefer; and it's totally OK to dive in and have a go; there is nothing sacred or magic about test frameworks that rules out rolling your own. When it comes to test frameworks, most of what I've seen so far is over-engineered crap in my eyes; that is my authentic experience from 32 years of writing code in umpteen languages.