Skip to content

Commit

Permalink
Revert "test: fix remaining 36 hello responses"
Browse files Browse the repository at this point in the history
This reverts commit 36eaa30.
  • Loading branch information
durran committed Oct 27, 2021
1 parent 36eaa30 commit 2422829
Show file tree
Hide file tree
Showing 10 changed files with 24 additions and 24 deletions.
4 changes: 2 additions & 2 deletions test/functional/buffering_proxy.test.js
Expand Up @@ -35,7 +35,7 @@ describe.skip('Buffering Proxy', function () {
var electionIds = [new ObjectId(0), new ObjectId(1)];

// Default message fields
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, {
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER, {
setName: 'rs',
setVersion: 1,
electionId: electionIds[0],
Expand Down Expand Up @@ -252,7 +252,7 @@ describe.skip('Buffering Proxy', function () {
var electionIds = [new ObjectId(0), new ObjectId(1)];

// Default message fields
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, {
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER, {
setName: 'rs',
setVersion: 1,
electionId: electionIds[0],
Expand Down
24 changes: 12 additions & 12 deletions test/functional/collations.test.js
Expand Up @@ -21,7 +21,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -57,7 +57,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -95,7 +95,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -131,7 +131,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -172,7 +172,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -208,7 +208,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -246,7 +246,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -282,7 +282,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -320,7 +320,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -356,7 +356,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -469,7 +469,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down Expand Up @@ -624,7 +624,7 @@ describe('Collation', function () {
test: function () {
const configuration = this.configuration;
const client = configuration.newClient(`mongodb://${testContext.server.uri()}/test`);
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER_36)];
const primary = [Object.assign({}, mock.DEFAULT_ISMASTER)];

let commandResult;
testContext.server.setMessageHandler(request => {
Expand Down
2 changes: 1 addition & 1 deletion test/functional/command_write_concern.test.js
Expand Up @@ -11,7 +11,7 @@ class WriteConcernTest {
this.configuration = configuration;
this.responseDecoration = {};
const electionIds = [new ObjectId(), new ObjectId()];
const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, {
const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER, {
setName: 'rs',
setVersion: 1,
electionId: electionIds[0],
Expand Down
2 changes: 1 addition & 1 deletion test/functional/max_staleness.test.js
Expand Up @@ -11,7 +11,7 @@ describe('Max Staleness', function () {
return mock.createServer().then(server => {
test.server = server;

const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, { msg: 'isdbgrid' });
const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER, { msg: 'isdbgrid' });

// Primary server states
const serverIsMaster = [Object.assign({}, defaultFields)];
Expand Down
4 changes: 2 additions & 2 deletions test/functional/replicaset_mock.test.js
Expand Up @@ -9,12 +9,12 @@ describe('ReplSet (mocks)', function () {
afterEach(() => mock.cleanup());
beforeEach(() => {
// Default message fields
const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, {
const defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER, {
msg: 'isdbgrid'
});

// Default message fields
const defaultRSFields = Object.assign({}, mock.DEFAULT_ISMASTER_36, {
const defaultRSFields = Object.assign({}, mock.DEFAULT_ISMASTER, {
setName: 'rs',
setVersion: 1,
electionId: new ObjectId(),
Expand Down
2 changes: 1 addition & 1 deletion test/functional/unit-sessions/client.test.js
Expand Up @@ -116,7 +116,7 @@ describe('Sessions - client/unit', function () {
var doc = request.document;
if (doc.ismaster || doc.hello) {
request.reply(
Object.assign({}, mock.DEFAULT_ISMASTER_36, {
Object.assign({}, mock.DEFAULT_ISMASTER, {
logicalSessionTimeoutMinutes: 10
})
);
Expand Down
2 changes: 1 addition & 1 deletion test/functional/unit_db_list_collections.test.js
Expand Up @@ -71,6 +71,6 @@ describe('db.listCollections', function () {
});
}

it(config.description, { test: testFn, metadata: { requires: { mongodb: '>=3.6.0' } } });
it(config.description, { test: testFn, metadata: { requires: { mongodb: '>=2.7.6' } } });
});
});
2 changes: 1 addition & 1 deletion test/functional/view.test.js
Expand Up @@ -13,7 +13,7 @@ describe('Views', function () {
const configuration = this.configuration;

// Default message fields
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER_36);
var defaultFields = Object.assign({}, mock.DEFAULT_ISMASTER);

// Primary server states
var primary = [Object.assign({}, defaultFields)];
Expand Down
4 changes: 2 additions & 2 deletions test/unit/_MISC_scram_iterations.test.js
Expand Up @@ -81,7 +81,7 @@ describe('SCRAM Iterations Tests', function () {
server.setMessageHandler(request => {
const doc = request.document;
if (doc.ismaster || doc.hello) {
return request.reply(Object.assign({}, mock.DEFAULT_ISMASTER_36));
return request.reply(Object.assign({}, mock.DEFAULT_ISMASTER));
} else if (doc.saslStart) {
return request.reply({
ok: 1,
Expand Down Expand Up @@ -128,7 +128,7 @@ describe('SCRAM Iterations Tests', function () {
server.setMessageHandler(request => {
const doc = request.document;
if (doc.ismaster || doc.hello) {
return request.reply(Object.assign({}, mock.DEFAULT_ISMASTER_36));
return request.reply(Object.assign({}, mock.DEFAULT_ISMASTER));
} else if (doc.saslStart) {
return request.reply({
ok: 1,
Expand Down
2 changes: 1 addition & 1 deletion test/unit/cursor/find_cursor.test.js
Expand Up @@ -31,7 +31,7 @@ describe('Find Cursor', function () {
const doc = request.document;
if (doc.ismaster || doc.hello) {
request.reply(
Object.assign({}, mock.DEFAULT_ISMASTER_36, {
Object.assign({}, mock.DEFAULT_ISMASTER, {
maxWireVersion: 6
})
);
Expand Down

0 comments on commit 2422829

Please sign in to comment.