You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the provided Gist, there are 3 tests.
In each of those tests, an observable is subscribed with the takeUntilDestroyed operator.
Therefore, we expect the observable's side effects to be isolated between each test.
The Gist shows that it is not the case with Spectator:
there are some console.log from the first tests which appear in the 2dn & in the 3rd tests.
Please provide the environment you discovered this bug in
Is this a regression?
No
Description
The operator
takeUntilDestroyed
is used to complete an observable when the calling context is destroyed:https://angular.dev/api/core/rxjs-interop/takeUntilDestroyed
TestBed
, when the context is destroyed, observables are well completedPlease provide a link to a minimal reproduction of the bug
https://gist.github.com/devfservant/65335449c0ab8241bd9af9d084f5232a
Disclaimer: I was not able to create a working Stackblitz with Angular 18 + Jest + Spectator 😕
(here is my last attempt: https://stackblitz.com/edit/stackblitz-starters-sspm11)
Please provide the exception or error you saw
In the provided Gist, there are 3 tests.
In each of those tests, an observable is subscribed with the
takeUntilDestroyed
operator.Therefore, we expect the observable's side effects to be isolated between each test.
The Gist shows that it is not the case with Spectator:
there are some
console.log
from the first tests which appear in the 2dn & in the 3rd tests.Please provide the environment you discovered this bug in
Anything else?
Note: I have no issue when using
@ngneat/until-destroy
library(but I want to use the new
takeUntilDestroyed
operator)Do you want to create a pull request?
No
The text was updated successfully, but these errors were encountered: