Fix Karma tests