Move server init menus after authentication is ready

This commit is contained in:
Yana De Pauw
2025-03-05 16:45:45 +01:00
parent 43e4f9de49
commit 4b3215412f
2 changed files with 2 additions and 2 deletions

View File

@@ -7,7 +7,7 @@ describe('Item Statistics Page', () => {
it('should load if you click on "Statistics" from an Item/Entity page', () => {
cy.visit('/entities/publication/'.concat(Cypress.env('DSPACE_TEST_ENTITY_PUBLICATION')));
cy.get('ds-navbar ds-link-menu-item a[data-test="link-menu-item.menu.section.statistics"]').click();
cy.location('pathname').should('eq', '/entities/publication/'.concat(Cypress.env('DSPACE_TEST_ENTITY_PUBLICATION')));
cy.location('pathname').should('eq', '/statistics/entities/publication/'.concat(Cypress.env('DSPACE_TEST_ENTITY_PUBLICATION')));
});
it('should contain element ds-item-statistics-page when navigating to an item statistics page', () => {

View File

@@ -83,9 +83,9 @@ export class ServerInitService extends InitService {
this.initAngulartics();
this.initRouteListeners();
this.themeService.listenForThemeChanges(false);
this.menuProviderService.initPersistentMenus();
await lastValueFrom(this.authenticationReady$());
this.menuProviderService.initPersistentMenus();
return true;
};