Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

jasmine spy return value when using create Spy Object angular 2

const loginResult = '';
const spy = spyOn(authService, 'login').and.callFake(() => {
    return Observable.from([loginResult]);
})
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #jasmine #spy #return #create #Spy #Object #angular
ADD COMMENT
Topic
Name
8+2 =