blob: f1a64953ee6225ca40cc6ed94520f35595bf9c74 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
/**
* Checks that listCommands returns the API Version information of a command.
*
* @tags: [requires_fcv_47, requires_non_retryable_commands]
*/
(function() {
"use strict";
const resListCommands = db.runCommand({listCommands: 1});
assert.commandWorked(resListCommands);
const {find, serverStatus, testDeprecation} = resListCommands["commands"];
assert(JSON.stringify(find.apiVersions) == "[\"1\"]");
assert(JSON.stringify(find.deprecatedApiVersions) == "[]");
assert(JSON.stringify(serverStatus.apiVersions) == "[]");
assert(JSON.stringify(serverStatus.deprecatedApiVersions) == "[]");
assert(JSON.stringify(testDeprecation.apiVersions) == "[\"1\"]");
assert(JSON.stringify(testDeprecation.deprecatedApiVersions) == "[\"1\"]");
})();
|