fixing bug in tests