Fixed configuration issue preventing unit tests for rules getting executed (#4466)

* Fixed configuration issue preventing unit tests for rules getting executed

* Added unit tests for SnackbarEffects to improve coverage

* Added unit tests for RouterEffects to improve coverage

* Excluding store actions, models, selectors and states from getting included in code coverage

* Added type to store
This commit is contained in:
swapnil-verma-gl
2025-03-21 15:44:12 +05:30
committed by GitHub
parent 1ef1976a4c
commit 8c1d2f3cd7
4 changed files with 392 additions and 6 deletions

View File

@@ -1424,19 +1424,16 @@ describe('app.evaluators', () => {
expect(app.canShowInfoDrawer(context)).toBeFalse();
});
it('should return false when user is in libraries or trashcan or details', () => {
it('should return false when user is in libraries or trashcan', () => {
context.selection.isEmpty = false;
context.navigation.url = '/trashcan/test';
expect(app.canShowInfoDrawer(context)).toBeFalse();
context.navigation.url = '/test/libraries';
expect(app.canShowInfoDrawer(context)).toBeFalse();
context.navigation.url = '/test/details';
expect(app.canShowInfoDrawer(context)).toBeFalse();
});
it('should return true when selection exists and user is not in trashcan, libraries or details', () => {
it('should return true when selection exists and user is not in trashcan, libraries', () => {
context.navigation.url = '/personal-files/test';
context.selection.isEmpty = false;
expect(app.canShowInfoDrawer(context)).toBeTrue();