From: Jdlrobson Date: Mon, 29 Jan 2018 19:47:07 +0000 (+0000) Subject: Revert "selenium: add new message banner test to user spec" X-Git-Tag: 1.31.0-rc.0~777^2 X-Git-Url: http://git.cyclocoop.org/%28?a=commitdiff_plain;h=33ba3cfebb9a45918296a6162c68caa514fdd116;p=lhc%2Fweb%2Fwiklou.git Revert "selenium: add new message banner test to user spec" This reverts commit 6ca3e221d1b907f55462394f910f283bb3627cc9. This is breaking CI for the Minerva skin and Echo as Echo changes how this interaction works. When the browser test tries to locate the div.usermessage it has moved so fails. This test needs to be rewritten to take this into account. On a side note, given usermessage is generated by all skins (and not in core) there is a big argument to be made that this shouldn't be in core but in the individual skins. MinervaNeue the mobile skin notably does not use this class so this test would always fail on a mediawiki instance which only uses the Minerva skin. Bug: T185928 Change-Id: I43b6cf328aaf4a4fded0bb9746716c4cc9d8f364 --- diff --git a/tests/selenium/pageobjects/usermessage.page.js b/tests/selenium/pageobjects/usermessage.page.js deleted file mode 100644 index 7faf34725e..0000000000 --- a/tests/selenium/pageobjects/usermessage.page.js +++ /dev/null @@ -1,7 +0,0 @@ -'use strict'; -const Page = require( './page' ); - -class UserMessagePage extends Page { - get usermessage() { return browser.element( 'div.usermessage' ); } -} -module.exports = new UserMessagePage(); diff --git a/tests/selenium/specs/user.js b/tests/selenium/specs/user.js index 102acd6fa4..3f3872dc7d 100644 --- a/tests/selenium/specs/user.js +++ b/tests/selenium/specs/user.js @@ -2,9 +2,7 @@ const assert = require( 'assert' ), CreateAccountPage = require( '../pageobjects/createaccount.page' ), PreferencesPage = require( '../pageobjects/preferences.page' ), - UserLoginPage = require( '../pageobjects/userlogin.page' ), - UserMessagePage = require( '../pageobjects/usermessage.page' ), - EditPage = require( '../pageobjects/edit.page' ); + UserLoginPage = require( '../pageobjects/userlogin.page' ); describe( 'User', function () { @@ -68,24 +66,4 @@ describe( 'User', function () { } ); - it( 'should be able to view new message banner', function () { - - // create user - browser.call( function () { - return CreateAccountPage.apiCreateAccount( username, password ); - } ); - - // create talk page with content - browser.call( function () { - return EditPage.apiEdit( 'User_talk:' + username, Math.random().toString() ); - } ); - - // log in - UserLoginPage.login( username, password ); - - // check - assert.equal( UserMessagePage.usermessage.getText(), 'You have a new message (last change).' ); - - } ); - } );