fixed a few tests for karma