From f43010678bb275476b309b1b1e4d0c429b93ffe5 Mon Sep 17 00:00:00 2001 From: Karl Dubost Date: Thu, 6 Aug 2015 14:15:27 +0900 Subject: [PATCH] #272 Adds login to the site --- tests/functional/labels.js | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/tests/functional/labels.js b/tests/functional/labels.js index 1f7fd26c4..197308b8d 100644 --- a/tests/functional/labels.js +++ b/tests/functional/labels.js @@ -14,6 +14,26 @@ define([ return intern.config.siteRoot + '/issues/' + num; }; -// labels tests to come here + registerSuite({ + name: 'labels', + 'log in': function () { + // for testing labels we need to be logged. + return this.remote + .setFindTimeout(intern.config.wc.pageLoadTimeout) + .get(require.toUrl(url(100))) + .findByCssSelector('.js-login-link').click() + .end() + .findByCssSelector('#login_field').click() + .type(intern.config.wc.user) + .end() + .findByCssSelector('#password').click() + .type(intern.config.wc.pw) + .end() + .findByCssSelector('input[type=submit]').submit() + .end() + .findByCssSelector('button').submit() + .end(); + }, + }); });