I want users to submit code and run tests against that code using AVA. The AVA CLI seems great. But this would be running in a hosted environment like Heroku and need to respond back to the POST request containing the code submission with the results of the unit tests.
When I try var test = require('ava')
and then call the test
function in a route, I get this message when starting the node server:
[OKAY] Loaded ENV .env File as KEY=VALUE Format
10:24:11 PM web.1 | Test files must be run with the AVA CLI:
10:24:11 PM web.1 | $ ava index.js
[DONE] Killing all processes with signal null
10:24:11 PM web.1 Exited with exit code 1