test(upgrade): fix failing test in browsers which do not support RAF
closes #13399
This commit is contained in:
parent
714f2af0dd
commit
d17e690eb4
|
@ -1023,6 +1023,13 @@ export function main() {
|
||||||
expect($onDestroySpy).toHaveBeenCalled();
|
expect($onDestroySpy).toHaveBeenCalled();
|
||||||
|
|
||||||
ref.dispose();
|
ref.dispose();
|
||||||
|
|
||||||
|
if (!(global as any)['requestAnimationFrame']) {
|
||||||
|
// Needed for browser which don't support RAF and use a 16.6 setTimeout instead in
|
||||||
|
// ng1's AnimateRunner.
|
||||||
|
// This setTimeout remains at the end of the test and needs to be discarded.
|
||||||
|
tick(20);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}));
|
}));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue