mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-09-24 23:01:18 +08:00
fix(curriculum): quality assurance test query id (#54646)
This commit is contained in:
+5
@@ -205,6 +205,11 @@ async (getUserInput) => {
|
||||
const getMultiple = await $.get(url + '?created_by=Alice&assigned_to=Bob');
|
||||
assert.isArray(getMultiple);
|
||||
assert.lengthOf(getMultiple, 2);
|
||||
const copyId = getMultiple[0]._id;
|
||||
const getById = await $.get(url + `?_id=${copyId}`);
|
||||
assert.isArray(getById);
|
||||
assert.lengthOf(getById, 1);
|
||||
assert.equal(getById[0]._id, copyId, 'should be able to query a document by _id')
|
||||
} catch (err) {
|
||||
throw new Error(err.responseText || err.message);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user