tests: Wrote tests for previously not-covered code.

Signed-off-by: Joe MacMahon <joe.macmahon@cern.ch>
tests: Fixed testfixtures error.

* Running ./run_tests.sh no longer runs testfixtures.tests

Signed-off-by: Joe MacMahon <joe.macmahon@cern.ch>