Two weeks ago I promised a blog post about the process we use for automating code samples verification in our #evitaDB documentation and now I'm keeping that promise.
The approach described, which takes advantage of #JUnit5 dynamic testing and #JShell REPL, looks like a novel approach. I haven't been able to Google any other project that documents something similar.
So if you have a similar use case, read on and get inspired.
The documentation on #evitaDB https://evitadb.io/documentation/index is getting bigger and bigger. The more examples we add, the more we're afraid they'll become obsolete or broken. How do we tame this beast of hundreds of examples?
Fortunately, #Java provides a JShell REPL that allows you to interactively enter, and run Java source code. The JShell can also be run automatically and #JUnit5 allows to create dynamic tests. Combining these two features we've created an automated test suite. Blog post coming.
Why did we choose @RedHat #Undertow server for #evitaDB web APIs (GraphQL/REST)?
It has a decent performance, nice API and is easy to embed. Read more about our testing and conclusions in the blog post: https://evitadb.io/blog/03-choosing-http-server