This is a sample for a CircuitSim tester that uses the circuitsim-tester library. The tested .sim files can be found in the tester directory. Note that this tester includes a number of Java files that each test a different .sim.
To build the tester jar, go to the tester/ directory, run ./gradlew jar and find the jar file in the build/libs directory.
- Clone this repository
- Remove the
.gitdirectory. - Edit the tester name in
tester/settings.gradle. - Add a GitHub Package Registry token to
tester/gradle.properties, as described here - Add any tests into the
tester/src/main/java/io/zucchini/samplecircuitsimtester/path, just like theANDTests.javafile. They will be discovered automatically. - If you want, change the
groupIdintester/build.gradle. - If you want, change the package the sources are in. Make sure to update tha
mainClassNamestring intester/build.gradleafterwards. - Build the autograder jar with
./gradlew jarin thetester/directory - Run the jar from the
files/directory and check for failing test cases - Profit!