Commit bb4de542 authored by Curtis Adam's avatar Curtis Adam

Update chimp tests

parent 0625bb56
......@@ -185,11 +185,11 @@ Template.welcome.helpers({
loginButtons += '<a id="BackdoorLogin" href=""><img src="img/backdoor-login.png" alt="use backdoor for' +
' login"/></a>';
loginButtons += '<span class="btn-group backdoorLogin"><label id="backdoor-label">' + title + ':</label><br><select class="btn btn-secondary btn-raised" id="TestingBackdoorUsername" aria-labelledby="backdoor-label">' +
'<option id="adminLogin" value="admin">' + superAdmin + '</option>' +
'<option id="editorLogin" value="editor">' + admin + '</option>' +
'<option id="superAdminLogin" value="admin">' + superAdmin + '</option>' +
'<option id="adminLogin" value="editor">' + admin + '</option>' +
'<option id="proLogin" value="pro">' + pro + '</option>' +
'<option id="lecturerLogin" value="lecturer">' + Meteor.settings.public.university.default + '-' + lecturer + '</option>' +
'<option id="universityLogin" value="university">' + Meteor.settings.public.university.default + '-' + edu + '</option>' +
'<option id="eduLogin" value="university">' + Meteor.settings.public.university.default + '-' + edu + '</option>' +
'<option id="standardLogin" value="standard">' + standard + '</option>' +
'<option id="blockedLogin" value="blocked">' + blocked + '</option>' +
'<option id="firstLogin" value="firstLogin">' + firstLogin + '</option>' +
......
......@@ -7,7 +7,7 @@ module.exports = function () {
let description = "description";
this.Given(/^User is logged in$/, function () {
navigation.login("universityLogin");
navigation.login("edu");
});
this.Given(/^User is on the my cardset view$/, function () {
......
......@@ -11,7 +11,7 @@ module.exports = function () {
* ---------------------------------------------------------------------
*/
this.Given(/^User is on the poolview with username "standard"$/, function () {
navigation.login("universityLogin");
navigation.login("edu");
});
this.Given(/^he is on the view of a cardset$/, function () {
navigation.selectMyCardset();
......
......@@ -7,7 +7,7 @@ module.exports = function () {
box5After, box6Before, box6After, card1, card2;
this.Given(/^I'm logged in$/, function () {
navigation.login("universityLogin");
navigation.login("edu");
});
this.Then(/^I'm at the leitner statistics to check my progress$/, function () {
......
......@@ -16,6 +16,7 @@ module.exports = {
browser.url(global.baseURL);
setResolution();
agreeCookies();
userLogin += "Login";
browser.waitForVisible('#TestingBackdoorUsername', global.threshold);
this.clickElement('#TestingBackdoorUsername', global.threshold);
browser.waitForVisible('#' + userLogin);
......
......@@ -16,9 +16,9 @@ if [ -z "$CALLED_FROM_SCRIPT" ] ; then
fi
if [ -n "$DISPLAY" ] ; then
xvfb-run --server-args="-ac -screen 0 1920x1080x24" chimp --ddp=http://localhost:3000 --path=$testDir $1 --browser=firefox
else
./node_modules/.bin/chimp .config/chimp.js --ddp=http://localhost:$PORT --path=$testDir $1 --browser=firefox
else
xvfb-run --server-args="-ac -screen 0 1920x1080x24" chimp --ddp=http://localhost:3000 --path=$testDir $1 --browser=firefox
fi
if [ $? -ne 0 ]; then
failedTests=$((failedTests+1))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment