1 // Copyright (C) The Arvados Authors. All rights reserved.
3 // SPDX-License-Identifier: AGPL-3.0
5 describe('Page not found tests', function() {
9 cy.getUser('admin', 'Admin', 'User', true, true)
10 .as('adminUser').then(function() {
11 adminUser = this.adminUser;
16 beforeEach(function() {
18 cy.clearLocalStorage()
21 it('shows not found page', function() {
23 cy.loginAs(adminUser);
24 cy.goToPath(`/this/is/an/invalid/route`);
27 cy.get('[data-cy=not-found-page]').should('exist');
28 cy.get('[data-cy=not-found-content]').should('exist');
32 it('shows not found popup', function() {
35 '/projects/zzzzz-j7d0g-nonexistingproj',
36 '/projects/zzzzz-tpzed-nonexistinguser',
37 '/processes/zzzzz-xvhdp-nonexistingproc',
38 '/collections/zzzzz-4zz18-nonexistingcoll'
39 ].forEach(function(path) {
40 // Using de slower loginAs() method to avoid bumping into dialog
41 // dismissal issues that are not related to this test.
42 cy.loginAs(adminUser);
48 cy.get('[data-cy=not-found-page]').should('not.exist');
49 cy.get('[data-cy=not-found-content]').should('exist');