Debian Codegraph @

skins/MinervaNeue/tests/selenium/specs/mainmenu_loggedin.js

raw symbols SCIP
1 'use strict';
2
3 const {
4 iAmLoggedIntoTheMobileWebsite,
5 iAmOnPage
6 } = require( '../features/step_definitions/common_steps' ),
7 { iSeeALinkToAboutPage, iShouldSeeAUserPageLinkInMenu,
8 iShouldSeeLogoutLinkInMenu,
9 iClickOnTheMainNavigationButton,
10 iShouldSeeALinkInMenu, iShouldSeeALinkToDisclaimer
11 } = require( '../features/step_definitions/menu_steps' );
12
13 // @chrome @en.m.wikipedia.beta.wmflabs.org @firefox @test2.m.wikipedia.org @vagrant @login
14 describe( 'Menus open correct page for anonymous users', () => {
15
16 beforeEach( async () => {
17 await iAmLoggedIntoTheMobileWebsite();
18 await iAmOnPage( 'Main Page' );
19 } );
20
21 it( 'Check links in menu', async () => {
22 await iClickOnTheMainNavigationButton();
23 await iShouldSeeALinkToDisclaimer();
24 await iShouldSeeAUserPageLinkInMenu();
25 await iSeeALinkToAboutPage();
26 [ 'Home', 'Random', 'Settings', 'Watchlist' ].forEach( async ( label ) => {
27 await iShouldSeeALinkInMenu( label );
28 } );
29 await iShouldSeeLogoutLinkInMenu();
30 try {
31 await iShouldSeeALinkInMenu( 'Nearby' );
32 } catch ( e ) {
33 console.warn( 'Nearby item will only appear in main menu if $wgMFNearby is configured' );
34 }
35 } );
36 } );