This repository was archived by the owner on Feb 26, 2024. It is now read-only.
This repository was archived by the owner on Feb 26, 2024. It is now read-only.
fakeAsync tests not working with lodash debounce #1050
Closed
Description
I had originally posted this issue to Angular angular/angular#22826
@JiaLiPassion requested me to re-submit the issue here.
I'm submitting a...
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ X ] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question
Current behavior
Using fakeAsync() and tick() to test functions that are debounced with lodash.debounce() do not work as expected.
Expected behavior
fakeAsync() and tick() should be able to be used to synchronously test debounced functions.
Minimal reproduction of the problem with instructions
I have a repository with a minimal reproduction: https://github.com/johnmcase/angular-test-debounce
Just clone, install, ng test
What is the motivation / use case for changing the behavior?
Environment
Angular version: 4.4.3 in the project I found this in. 5.2.0 in minimal reproduction
Browser:
- [ X ] Chrome (desktop) version XX
- [ ] Chrome (Android) version XX
- [ ] Chrome (iOS) version XX
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] Safari (iOS) version XX
- [ ] IE version XX
- [ ] Edge version XX
For Tooling issues:
- Node version: 6.12.0
- Platform: Windows 10
Others:
Metadata
Metadata
Assignees
Labels
No labels