mvysny / dynatest Goto Github PK
View Code? Open in Web Editor NEWSimplest & Powerful Testing Framework For Kotlin. No annotations!
License: Apache License 2.0
Simplest & Powerful Testing Framework For Kotlin. No annotations!
License: Apache License 2.0
First and foremost, this looks like an interesting test framework, and it's always cool to see people implementing their own TestEngine
for the JUnit Platform!
I read through the README
and noticed a few points regarding JUnit Jupiter's support for parameterized tests which are technically incorrect.
So I'd be grateful if you could reword the following sections.
Thanks in advance!
- The support for parametrized tests with JUnit5 is quite limited: the parameters need to be known upfront and stored in annotations, that restricts you from:
Parameters actually do not need to be known up front. They can be loaded from any source of your choosing dynamically and programmatically. You can implement a custom ArgumentsProvider
or use a @MethodSource
that receives parameters that are dynamically supplied by a factory method.
One can of course choose to use an annotation such as @ValueSource
to define static parameters, but that is not the only choice.
- Having the parameters created dynamically or loaded from a file;
So you could generate the parameters dynamically, load them from a file, read them from a database, etc. The world is your oyster. ๐
- Using more complex types - you are restricted to String and primitives.
There are literally zero restrictions on parameter types when using a @MethodSource
or custom ArgumentsProvider
.
Implement test filtering based on UniqueIdSelector when https://youtrack.jetbrains.com/issue/IDEA-169198 is fixed
There is no clear distinction between the code that creates tests (calls the test()
method), and
the testing code itself (blocks inside of test()
method). However, there is a ton of difference:
those two code bases run at completely different time. Furthermore Kotlin allows to share variables
freely between those two code bases, which may create a really dangerous code which fails in mysterious ways.
That's magic which must be removed. The test()
method must yell a big warning sign that the programmer is crossing code boundaries. I'm thinking about renaming the test()
method to something else, but I'm not really satisfied with any of the candidates:
post()
- not really a testpostTest()
- too longtest()
deprecated - stupid :-)Even a simple test suite freezes Gradle when running on JDK 11 (also OpenJDK 10 and OpenJDK 9). You can reproduce this bug easily by running ./gradlew
on the https://github.com/mvysny/karibu-helloworld-application example app. The build passes on OpenJDK 8.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.