MovingBlocks

Add some unit tests!

Every project loves unit tests, but few have enough!

Our engine has about 600 tests, which is nowhere near enough, yet modules often have none at all.

Your task is to find a module without tests, containing logic that can be tested, then adding some tests to validate some / all of the logic.

Definition of 'Done'

  • A PR is submitted to a module repo containing new tests for any module repo with code to unit test.
  • Include a screenshot of successful test output or copy the output

Where to start

  • Read the introduction to unit testing for an introduction to unit testing and the general philosophy of why.
  • See some of the unit tests in the engine or the few modules that do have unit tests (like the NameGenerator or SimpleFarming) for inspiration.
  • Look for a module with code in it that is lacking tests. Look through the list of all modules and look for a src/main/test path - that's where tests would exist

See also

Task tags

  • test
  • modules
  • java
  • unit test

Students who completed this task

eviltak, Jason Huang, Max Borsch

Task type

  • code Code
close

2017