-
-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix test after latest changes and fix flaky test. #770
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Split beforeEach into async and sync.
This module allows importing e.g. "keys" pipe in tests without having to import SharedModule. Use this in all the tests instead of declaring the Pipes in the testing module, which should only declare the component under test.
New use of Device.
New use of ngModel, add FormsModule import. While here, replace TranslatePipe declaration and use of TranslateServiceMock with TranslateModule imports.
New use of Device.
New use of storage. While here, replace TranslatePipe declaration and use of TranslateServiceMock with TranslateModule imports.
During the tests, `this.settings` is not set. This was causing a failure in onDestroy and prevent the component from being cleaned up properly. This resulted in random failures in unrelated tests with the error: ``` Uncaught Error: Uncaught (in promise): TypeError: _this5.brewComponent.timer?.isTimerRunning is not a function TypeError: _this5.brewComponent.timer?.isTimerRunning is not a function at http://localhost:9876/_karma_webpack_/webpack:/src/components/brews/brew-brewing-graph/brew-brewing-graph.component.ts:1319:35 ```
Quality Gate passedIssues Measures |
Closed
Thanks for the PR and all the effort you took into it! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
develop
.PipesModule
to import pipes without having to importSharedModule
. Import it in all test modules instead of declaringXPipe
classes.BrewBrewingGraphComponent.destroy
during tests whenthis.settings
was not initialised.Resolves #730.
Once this is merged, the tests should be in a good enough state to submit the GitHub Action to run tests automatically for #740.