Updating tests to reflect graphql changes.

This commit is contained in:
David Jay
2017-01-26 14:41:03 -05:00
parent aa83aea849
commit 2e34f726eb
6 changed files with 20 additions and 18 deletions
+6 -6
View File
@@ -1,20 +1,20 @@
require('babel-core/register');
module.exports = {
'src_folders': './tests/e2e/tests',
'output_folder': './tests/e2e/reports',
'page_objects_path': './tests/e2e/pages',
'globals_path': './tests/e2e/globals',
'src_folders': './test/e2e/tests',
'output_folder': './test/e2e/reports',
'page_objects_path': './test/e2e/pages',
'globals_path': './test/e2e/globals',
'custom_commands_path' : '',
'custom_assertions_path' : '',
'selenium': {
'start_process': true,
'server_path': 'node_modules/selenium-standalone/.selenium/selenium-server/2.53.1-server.jar',
'log_path': './tests/e2e/reports',
'log_path': './test/e2e/reports',
'host': '127.0.0.1',
'port': 6666,
'cli_args': {
'webdriver.chrome.driver': 'node_modules/selenium-standalone/.selenium/chromedriver/2.25-x64-chromedriver'
'webdriver.chrome.driver': 'node_modules/selenium-standalone/.selenium/chromedriver/2.27-x64-chromedriver'
}
},
'test_settings': {
+2 -2
View File
@@ -4,10 +4,10 @@
selenium-standalone install
# Creating Admin Test User
./bin/cli users create --flag_mode --email "admin@test.com" --password "testtest" --name "AdminTestUser" --role "admin"
./bin/cli users create --flag_mode --email "admin@test.com" --password "testtest" --name "AdminTestUser" --role "ADMIN"
# Creating Moderator Test User
./bin/cli users create --flag_mode --email "moderator@test.com" --password "testtest" --name "ModeratorTestUser" --role "moderator"
./bin/cli users create --flag_mode --email "moderator@test.com" --password "testtest" --name "ModeratorTestUser" --role "MODERATOR"
# Creating Commenter Test User
./bin/cli users create --flag_mode --email "commenter@test.com" --password "testtest" --name "CommenterTestUser"
+8 -6
View File
@@ -1,8 +1,8 @@
const Comments = require('../../models/comment');
const Users = require('../../models/user');
const Actions = require('../../models/action');
const Assets = require('../../models/asset');
const Settings = require('../../models/setting');
const Comments = require('../../services/comments');
const Users = require('../../services/users');
const Actions = require('../../services/actions');
const Assets = require('../../services/assets');
const Settings = require('../../services/settings');
const globals = require('./globals');
/* Create an array of comments */
@@ -22,4 +22,6 @@ module.exports.users = (users) => Users.createLocalUsers(users);
module.exports.actions = (actions) => Actions.create(actions);
/* Update a setting */
module.exports.settings = (setting) => Settings.init().then(() => Settings.updateSettings(setting));
module.exports.settings = (setting) => Settings.init().then(() => {
Settings.updateSettings(setting);
});
+2 -2
View File
@@ -127,10 +127,10 @@ module.exports = {
selector: '.comment .coral-plugin-flags-popup'
},
flagCommentOption: {
selector: '.comment .coral-plugin-flags-popup .coral-plugin-flags-popup-radio-label[for="comments"]'
selector: '.comment .coral-plugin-flags-popup .coral-plugin-flags-popup-radio-label[for="COMMENTS"]'
},
flagUsernameOption: {
selector: '.comment .coral-plugin-flags-popup .coral-plugin-flags-popup-radio-label[for="user"]'
selector: '.comment .coral-plugin-flags-popup .coral-plugin-flags-popup-radio-label[for="USERS"]'
},
flagOtherOption: {
selector: '.comment .coral-plugin-flags-popup .coral-plugin-flags-popup-radio-label[for="other"]'
+1 -1
View File
@@ -170,7 +170,7 @@ module.exports = {
// Verify that comment count is correct
client.waitForElementVisible('.coral-plugin-comment-count-text', 2000)
.assert.containsText('.coral-plugin-comment-count-text', '1 Comment');
.assert.containsText('.coral-plugin-comment-count-text', '2 Comments');
done();
});
},
+1 -1
View File
@@ -13,7 +13,7 @@ module.exports = {
embedStreamPage
.signUp({
email: `visitor_${Date.now()}@test.com`,
displayName: 'visitor',
displayName: `visitor${Date.now()}`,
pass: 'testtest'
});
},