mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2024-08-18 19:59:24 +00:00
![Jonathan Coates](/assets/img/avatar_default.png)
Name a more iconic duo than @SquidDev and over-engineered test frameworks. This uses Minecraft's test core[1] plus a home-grown framework to run tests against computers in-world. The general idea is: - Build a structure in game. - Save the structure to a file. This will be spawned in every time the test is run. - Write some code which asserts the structure behaves in a particular way. This is done in Kotlin (shock, horror), as coroutines give us a nice way to run asynchronous code while still running on the main thread. As with all my testing efforts, I still haven't actually written any tests! It'd be good to go through some of the historic ones and write some tests though. Turtle block placing and computer redstone interactions are probably a good place to start. [1]: https://www.youtube.com/watch?v=vXaWOJTCYNg
4 lines
139 B
Plaintext
4 lines
139 B
Plaintext
# Ignore changes in generated files
|
|
src/generated/resources/data/** linguist-generated
|
|
src/test/server-files/structures linguist-generated
|