Thursday, March 29, 2012

Updating the unit tests

Before doing more changes I thought of checking the unit tests and what they're doing right now. There are several projects in the UnitTests folder, each of them containing groups of tests.

They all run using the nunit-x86.exe file that is in $(repPath)\Lib\NUnit\bin\ so the installed version of Nunit doesn't matter. To run each of them, simply set them as startup project and run. You might notice that some of them have the output type 'Class Library' and opening them from your own installation of Nunit doesn't work - they are set up to run from the project configuration panel, the Debug tab.

Today I worked on the tests in the MetaActionTests project. There are two ways of constructing the shapes there: adding mouse clicks and adding the dependecy objects. I fixed some of the tests that added mouse clicks and didn't use the new node structure and added some more asserts so it's clear not only how many nodes we're expecting, but also what they should be. For the other type of tests, the ProposeCandidate and PushValue calls from ShapeBuildHelp.cs need to be updated to use references and the tests need to be updated to use the changed setup object.


No comments: