As already mentioned in #1749, could spyOn have automatic restore as jasmine has?
It would help to isolate spies for given test, as its simple to forget to call the restore at the end of the test (and can affect the other tests which is always difficult to track down).
And also there is no guarantee that the restore will get called, because test might fail in some expect, which stops the execution of the test and prevents calling the restore, which is usually called at the end of the test function.
As already mentioned in #1749, could
spyOnhave automatic restore as jasmine has?It would help to isolate spies for given test, as its simple to forget to call the restore at the end of the test (and can affect the other tests which is always difficult to track down).
And also there is no guarantee that the restore will get called, because test might fail in some
expect, which stops the execution of the test and prevents calling the restore, which is usually called at the end of the test function.