write a test by jasmine