fixed bug in HandlerTests