add tests
fixing bug :)