Github user robertkowalski commented on a diff in the pull request:
https://github.com/apache/couchdb-fauxton/pull/423#discussion_r30642107
--- Diff: test/nightwatch_tests/helpers/helpers.js ---
@@ -25,23 +26,31 @@ module.exports = {
console.log("nano setting up database");
// clean up the database we created previously
- nano.db.destroy(database, function (err, body, header) {
- if (err) {
- if (err.message != 'Database does not exist.' && err.message !=
'missing') {
- console.log('Error in setting up ' + database, err.message);
- }
- }
- // create a new database
- nano.db.create(database, function (err, body, header) {
- if (err) {
- console.log('Error in setting up ' + database, err.message);
- }
+ async.parallel([
+ function (cb) {
+ nano.db.destroy(database, function (err, body, header) {
+ if (err && err.message !== 'Database does not exist.' &&
err.message !== 'missing') {
+ console.log('Error in setting up ' + database, err.message);
+ }
+ // create a new database
+ nano.db.create(database, function (err, body, header) {
+ if (err) {
+ console.log('Error in setting up ' + database, err.message);
+ }
+ cb();
+ });
+ });
+ },
+ function (cb) {
nano.db.create('_replicator', function (err, body, header) {
--- End diff --
we depend on the replicator db in our tests, but once the cassim race
condition is fixed, we will have other systemdbs for testing automatically on
the cluster
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---