mudcoders / guildmud

A SocketMUD-based Multi-User Dungeon built and managed by the members of The MUD Coders Guild.
MIT License
26 stars 12 forks source link

Add testing infrastructure #17

Closed rogersm closed 6 years ago

rogersm commented 6 years ago

Some small steps to add testing infrastructure to close Issue #11:

  1. For the tests to run Check needs to be installed in your OS or vagrant.
  2. Tests should be written in the $(ROOT)/tests/ directory using the check syntax. Additional info can be found reading the man page:
    # man checkmk
  3. Also, tests can be coded directly in C in $(ROOT)/tests/ directory, no problem with that. I plan to add a sample shortly, but if you do it before me and the Makefile is unable to compile them, please open an issue and I'll check.
  4. Test samples are fairly inconsequential :)
  5. The Makefile doesn't run the tests, this has to be done manually or via CI running the binaries compiled by the Makefile in $(ROOT)/tests/ directory. They can be identified by the .run extension. @zachflower can you add them to Travis CI?