Skip to content

Commit

Permalink
spec sync and unskip now passing spec tests
Browse files Browse the repository at this point in the history
  • Loading branch information
baileympearson committed Feb 11, 2022
1 parent 15127fe commit 182caa1
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 24 deletions.
24 changes: 14 additions & 10 deletions test/spec/uri-options/connection-options.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,8 @@
"valid": false,
"warning": false,
"hosts": null,
"auth": null
"auth": null,
"options": {}
},
{
"description": "directConnection=false",
Expand Down Expand Up @@ -179,6 +180,18 @@
"loadBalanced": true
}
},
{
"description": "loadBalanced=true with directConnection=false",
"uri": "mongodb://example.com/?loadBalanced=true&directConnection=false",
"valid": true,
"warning": false,
"hosts": null,
"auth": null,
"options": {
"loadBalanced": true,
"directConnection": false
}
},
{
"description": "loadBalanced=false",
"uri": "mongodb://example.com/?loadBalanced=false",
Expand Down Expand Up @@ -217,15 +230,6 @@
"auth": null,
"options": {}
},
{
"description": "loadBalanced=true with directConnection=false causes an error",
"uri": "mongodb://example.com/?loadBalanced=true&directConnection=false",
"valid": false,
"warning": false,
"hosts": null,
"auth": null,
"options": {}
},
{
"description": "loadBalanced=true with replicaSet causes an error",
"uri": "mongodb://example.com/?loadBalanced=true&replicaSet=replset",
Expand Down
22 changes: 12 additions & 10 deletions test/spec/uri-options/connection-options.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ tests:
hosts: ~
auth: ~
options: {}
-
-
description: "Invalid retryWrites causes a warning"
uri: "mongodb://example.com/?retryWrites=invalid"
valid: true
Expand Down Expand Up @@ -104,7 +104,6 @@ tests:
hosts: ~
auth: ~
options: {}

-
description: directConnection=true
uri: "mongodb://example.com/?directConnection=true"
Expand All @@ -121,6 +120,7 @@ tests:
warning: false
hosts: ~
auth: ~
options: {}
-
description: directConnection=false
uri: "mongodb://example.com/?directConnection=false"
Expand Down Expand Up @@ -156,6 +156,16 @@ tests:
auth: ~
options:
loadBalanced: true
-
description: loadBalanced=true with directConnection=false
uri: "mongodb://example.com/?loadBalanced=true&directConnection=false"
valid: true
warning: false
hosts: ~
auth: ~
options:
loadBalanced: true
directConnection: false
-
description: loadBalanced=false
uri: "mongodb://example.com/?loadBalanced=false"
Expand Down Expand Up @@ -189,14 +199,6 @@ tests:
hosts: ~
auth: ~
options: {}
-
description: loadBalanced=true with directConnection=false causes an error
uri: "mongodb://example.com/?loadBalanced=true&directConnection=false"
valid: false
warning: false
hosts: ~
auth: ~
options: {}
-
description: loadBalanced=true with replicaSet causes an error
uri: "mongodb://example.com/?loadBalanced=true&replicaSet=replset"
Expand Down
4 changes: 0 additions & 4 deletions test/unit/assorted/uri_options.spec.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ describe('URI option spec tests', function () {
const suites = loadSpecTests('uri-options');

const skipTests = [
// TODO(NODE-3917): Fix directConnection and loadBalanced option validation
'directConnection=true with multiple seeds',
'loadBalanced=true with directConnection=false causes an error',

// Skipped because this does not apply to Node
'Valid options specific to single-threaded drivers are parsed correctly',

Expand Down

0 comments on commit 182caa1

Please sign in to comment.