mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-11-27 23:50:30 +00:00
Merge "Skip the flaking watchstar test"
This commit is contained in:
commit
cd7a50682f
|
@ -19,7 +19,8 @@ const login = () => {
|
|||
|
||||
const createPages = ( pages ) => {
|
||||
const summary = 'edit by selenium test';
|
||||
return login().then( () =>
|
||||
browser.call( () => login() );
|
||||
browser.call( () =>
|
||||
api.batch(
|
||||
pages.map( ( page ) => [ 'create' ].concat( page ).concat( [ summary ] ) )
|
||||
)
|
||||
|
@ -27,7 +28,8 @@ const createPages = ( pages ) => {
|
|||
};
|
||||
|
||||
const createPage = ( title, wikitext ) => {
|
||||
return login().then( () => Api.edit( title, wikitext ) );
|
||||
browser.call( () => login() );
|
||||
browser.call( () => Api.edit( title, wikitext ) );
|
||||
};
|
||||
|
||||
const iAmUsingTheMobileSite = () => {
|
||||
|
@ -56,11 +58,11 @@ const iAmLoggedIntoTheMobileWebsite = () => {
|
|||
};
|
||||
|
||||
const pageExists = ( title ) => {
|
||||
return createPage( title, 'Page created by Selenium browser test.' ).then( () => {
|
||||
const d = new Date();
|
||||
// wait 2 seconds so the change can propogate.
|
||||
browser.waitUntil( () => new Date() - d > 2000 );
|
||||
} );
|
||||
browser.call( () =>
|
||||
createPage( title, 'Page created by Selenium browser test.' )
|
||||
);
|
||||
// wait 2 seconds so the change can propogate.
|
||||
waitForPropagation( 2000 );
|
||||
};
|
||||
|
||||
const iAmOnAPageThatDoesNotExist = () => {
|
||||
|
|
|
@ -13,7 +13,7 @@ const {
|
|||
} = require( '../features/step_definitions/search_steps' );
|
||||
|
||||
// @test2.m.wikipedia.org @vagrant @login
|
||||
describe( 'Search', () => {
|
||||
describe.skip( 'Search', () => {
|
||||
|
||||
it( 'Clicking on a watchstar toggles the watchstar', () => {
|
||||
iAmUsingTheMobileSite();
|
||||
|
|
|
@ -19,12 +19,15 @@ const { iAmOnAPageWithNoTalkTopics } = require( '../features/step_definitions/cr
|
|||
// @chrome @en.m.wikipedia.beta.wmflabs.org @firefox @test2.m.wikipedia.org @vagrant
|
||||
describe( 'Talk', () => {
|
||||
|
||||
beforeEach( () => {
|
||||
iAmUsingTheMobileSite();
|
||||
before( () => {
|
||||
pageExists( 'Talk:Selenium talk test' );
|
||||
pageExists( 'Selenium talk test' );
|
||||
} );
|
||||
|
||||
beforeEach( () => {
|
||||
iAmUsingTheMobileSite();
|
||||
} );
|
||||
|
||||
it( 'Add discussion on talk page not possible as logged out user', () => {
|
||||
iAmOnPage( 'Selenium talk test' );
|
||||
thereShouldBeNoTalkButton();
|
||||
|
|
Loading…
Reference in a new issue