Skip to content

Getting Java Testcases in repl.it

repl.it uses JUnit for testing, however the unit test files only appear when running the test, and got deleted after tests are finished.

We can run watch -n 0.5 ls -lh to figure out the name of the unit test file. (it's probably named _test_runnerTestSuite.java)

Then, just cat _test_runnerTestSuite.java while the test is running.

Here's the unit test file from one of my assignments: gist


Last update: June 26, 2021
Created: March 24, 2021