mongoose challenges: check for db connection (#16987)

This commit is contained in:
Emanuele Antonelli
2018-04-28 10:22:47 +02:00
committed by mrugesh mohapatra
parent fa1cc4a436
commit 06b4c95472

View File

@ -85,6 +85,10 @@
{ {
"text": "\"mongoose\" dependency should be in package.json", "text": "\"mongoose\" dependency should be in package.json",
"testString": "getUserInput => $.get(getUserInput('url') + '/_api/file/package.json').then(data => { var packJson = JSON.parse(data); assert.property(packJson.dependencies, 'mongoose'); }, xhr => { throw new Error(xhr.responseText); })" "testString": "getUserInput => $.get(getUserInput('url') + '/_api/file/package.json').then(data => { var packJson = JSON.parse(data); assert.property(packJson.dependencies, 'mongoose'); }, xhr => { throw new Error(xhr.responseText); })"
},
{
"text": "\"mongoose\" should be connected to a database",
"testString": "getUserInput => $.get(getUserInput('url') + '/_api/is-mongoose-ok').then(data => {assert.isTrue(data.isMongooseOk, 'mongoose is not connected')}, xhr => { throw new Error(xhr.responseText); })"
} }
], ],
"solutions": [], "solutions": [],