Skip to content

Jasmine Cheatsheet

Jason Lewis edited this page Mar 13, 2024 · 1 revision

Up

Method Execution

Has Method Been Called

expect(<method>).toHaveBeenCalled()

Has Method Been Called with Specific Parameters

expect(<method>).toHaveBeenCalledWith(<parameter values>)

Has Method NOT Been Called

expect(<method>).not.toHaveBeenCalled()

Clone this wiki locally