added asserts on a test
fixed bug in a test, refactored other tests structure