You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by be...@apache.org on 2015/05/12 20:01:36 UTC
fauxton commit: updated refs/heads/master to 21254ad
Repository: couchdb-fauxton
Updated Branches:
refs/heads/master 860a808b4 -> 21254ad12
Improvement to nightwatch tests
Project: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/commit/21254ad1
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/tree/21254ad1
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/diff/21254ad1
Branch: refs/heads/master
Commit: 21254ad12a1baf2f2733355e796d3778a3c3fa99
Parents: 860a808
Author: Ben Keen <be...@gmail.com>
Authored: Tue May 12 09:44:21 2015 -0700
Committer: Ben Keen <be...@gmail.com>
Committed: Tue May 12 10:26:10 2015 -0700
----------------------------------------------------------------------
.../tests/nightwatch/deletesDatabaseSpecialChars.js | 6 +++---
.../databases/tests/nightwatch/switchDatabase.js | 3 +++
.../tests/nightwatch/deleteDatabaseModal.js | 16 ++++++++--------
.../documents/tests/nightwatch/viewSaveManyTimes.js | 1 +
4 files changed, 15 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/21254ad1/app/addons/databases/tests/nightwatch/deletesDatabaseSpecialChars.js
----------------------------------------------------------------------
diff --git a/app/addons/databases/tests/nightwatch/deletesDatabaseSpecialChars.js b/app/addons/databases/tests/nightwatch/deletesDatabaseSpecialChars.js
index 0ff4feb..b78bcd2 100644
--- a/app/addons/databases/tests/nightwatch/deletesDatabaseSpecialChars.js
+++ b/app/addons/databases/tests/nightwatch/deletesDatabaseSpecialChars.js
@@ -21,11 +21,11 @@ module.exports = {
.loginToGUI()
.url(baseUrl + '/#/database/' + encodeURIComponent(newDatabaseName) + '/_all_docs')
.waitForElementPresent('#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog', waitTime, false)
- .click("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog")
+ .clickWhenVisible("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog", waitTime, false)
.waitForElementPresent('#header-dropdown-menu .fonticon-trash', waitTime, false)
- .click('#header-dropdown-menu .fonticon-trash')
+ .clickWhenVisible('#header-dropdown-menu .fonticon-trash', waitTime, false)
.waitForElementVisible('#db_name', waitTime, false)
- .click('#db_name')
+ .clickWhenVisible('#db_name', waitTime, false)
.setValue('input#db_name', [newDatabaseName, client.Keys.ENTER] )
.waitForElementVisible('#global-notifications .alert.alert-info', waitTime, false)
.url(baseUrl + '/_all_dbs')
http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/21254ad1/app/addons/databases/tests/nightwatch/switchDatabase.js
----------------------------------------------------------------------
diff --git a/app/addons/databases/tests/nightwatch/switchDatabase.js b/app/addons/databases/tests/nightwatch/switchDatabase.js
index 137bb92..79f2e7c 100644
--- a/app/addons/databases/tests/nightwatch/switchDatabase.js
+++ b/app/addons/databases/tests/nightwatch/switchDatabase.js
@@ -20,6 +20,9 @@ module.exports = {
// wait for the DB name typeahead field to appear in the header
.waitForElementPresent('#jump-to-db .search-autocomplete', waitTime, false)
+
+ // wait for DBs to show up
+ .waitForElementPresent('a[href="#/database/' + newDatabaseName + '/_all_docs"]', waitTime, false)
.setValue('#jump-to-db .search-autocomplete', [newDatabaseName, client.Keys.ENTER])
.waitForElementPresent('.index-pagination', waitTime, false)
http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/21254ad1/app/addons/documents/tests/nightwatch/deleteDatabaseModal.js
----------------------------------------------------------------------
diff --git a/app/addons/documents/tests/nightwatch/deleteDatabaseModal.js b/app/addons/documents/tests/nightwatch/deleteDatabaseModal.js
index 973e455..935b2c4 100644
--- a/app/addons/documents/tests/nightwatch/deleteDatabaseModal.js
+++ b/app/addons/documents/tests/nightwatch/deleteDatabaseModal.js
@@ -18,10 +18,10 @@ module.exports = {
client
.loginToGUI()
.url(baseUrl + '/#/database/_replicator/_all_docs')
- .waitForElementPresent('#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog', waitTime, false)
- .click("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog")
- .waitForElementPresent('#header-dropdown-menu .fonticon-trash', waitTime, false)
- .click('#header-dropdown-menu .fonticon-trash')
+ .waitForElementPresent("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog", waitTime, false)
+ .clickWhenVisible("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog", waitTime, false)
+ .waitForElementPresent("#header-dropdown-menu .fonticon-trash", waitTime, false)
+ .clickWhenVisible('#header-dropdown-menu .fonticon-trash', waitTime, false)
.waitForElementVisible('#db_name', waitTime, false)
.assert.elementPresent('.warning')
.end();
@@ -35,10 +35,10 @@ module.exports = {
client
.loginToGUI()
.url(baseUrl + '/#/database/' + newDatabaseName + '/_all_docs')
- .waitForElementPresent('#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog', waitTime, false)
- .click("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog")
- .waitForElementPresent('#header-dropdown-menu .fonticon-trash', waitTime, false)
- .click('#header-dropdown-menu .fonticon-trash')
+ .waitForElementPresent("#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog", waitTime, false)
+ .clickWhenVisible('#header-dropdown-menu a.dropdown-toggle.icon.fonticon-cog', waitTime, false)
+ .waitForElementPresent("#header-dropdown-menu .fonticon-trash", waitTime, false)
+ .clickWhenVisible('#header-dropdown-menu .fonticon-trash', waitTime, false)
.waitForElementVisible('#db_name', waitTime, false)
.assert.elementNotPresent('.warning')
.end();
http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/21254ad1/app/addons/documents/tests/nightwatch/viewSaveManyTimes.js
----------------------------------------------------------------------
diff --git a/app/addons/documents/tests/nightwatch/viewSaveManyTimes.js b/app/addons/documents/tests/nightwatch/viewSaveManyTimes.js
index 6f6570d..aad9409 100644
--- a/app/addons/documents/tests/nightwatch/viewSaveManyTimes.js
+++ b/app/addons/documents/tests/nightwatch/viewSaveManyTimes.js
@@ -27,6 +27,7 @@ module.exports = {
.click(dropDownElement + ' a')
.click(dropDownElement + ' a[href*="new_view"]')
.waitForElementPresent('.editor-wrapper', waitTime, false)
+ .waitForElementPresent('#new-ddoc', waitTime, false)
.setValue('#new-ddoc', 'test_design_doc-save-many-times')
.clearValue('#index-name')
.setValue('#index-name', 'multiple-saves')