fixed test cases, moved assert test to test/testassert.cpp
fixes for test cases: local variables can also be modified