make test work in karma.