Friday, April 30, 2010

Meta Action Unit Tests

A tool like the line tool has two main parts:
- a Function that knows how to build the shape from its dependencies (like building a line from 2 points given as dependencies),
- a Meta Action that collects data from mouse and command line, sets the function dependencies and executes it to build the shape.

To improve the code quality and detect bugs as soon as possible we implemented Lua scripts that execute all Functions from all tools to see if they are broken or not.

Now started developing unit tests that check the Meta Actions. Finalized the code that configures and sets all elements (stubs for views, pipes through which mouse points are transmitted, etc) needed for tests. Will continue with implementing for the point tool the actual tests that checks if it is ok.

No comments: