Fixing test case.
This commit is contained in:
parent
84afa832c5
commit
28584a01db
|
@ -33,7 +33,7 @@ exports.getCouchInfo = () => {
|
||||||
} else if (urlInfo.auth.username) {
|
} else if (urlInfo.auth.username) {
|
||||||
// set from url
|
// set from url
|
||||||
username = urlInfo.auth.username
|
username = urlInfo.auth.username
|
||||||
} else {
|
} else if (!env.isTest()) {
|
||||||
throw new Error("CouchDB username not set")
|
throw new Error("CouchDB username not set")
|
||||||
}
|
}
|
||||||
if (env.COUCH_DB_PASSWORD) {
|
if (env.COUCH_DB_PASSWORD) {
|
||||||
|
@ -42,7 +42,7 @@ exports.getCouchInfo = () => {
|
||||||
} else if (urlInfo.auth.password) {
|
} else if (urlInfo.auth.password) {
|
||||||
// set from url
|
// set from url
|
||||||
password = urlInfo.auth.password
|
password = urlInfo.auth.password
|
||||||
} else {
|
} else if (!env.isTest()) {
|
||||||
throw new Error("CouchDB password not set")
|
throw new Error("CouchDB password not set")
|
||||||
}
|
}
|
||||||
const authCookie = Buffer.from(`${username}:${password}`).toString("base64")
|
const authCookie = Buffer.from(`${username}:${password}`).toString("base64")
|
||||||
|
|
Loading…
Reference in New Issue