Skip to content

Commit dec3ddf

Browse files
committed
updates
1 parent 5d29b75 commit dec3ddf

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

mongo/integration/unified_spec_test.go

+4-9
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ const (
4242
gridFSFiles = "fs.files"
4343
gridFSChunks = "fs.chunks"
4444
spec1403SkipReason = "servers less than 4.2 do not have mongocryptd; see SPEC-1403"
45-
godriver2123SkipReason = "failpoints and timeouts together cause failures; see GODRIVER-2123"
4645
godriver2413SkipReason = "encryptedFields argument is not supported on Collection.Drop; see GODRIVER-2413"
4746
)
4847

@@ -52,14 +51,10 @@ var (
5251
// SPEC-1403: This test checks to see if the correct error is thrown when auto encrypting with a server < 4.2.
5352
// Currently, the test will fail because a server < 4.2 wouldn't have mongocryptd, so Client construction
5453
// would fail with a mongocryptd spawn error.
55-
"operation fails with maxWireVersion < 8": spec1403SkipReason,
56-
// GODRIVER-2123: The test below use a failpoint and a socket or server selection timeout.
57-
// The timeout causes the eventual clearing of the failpoint in the test runner to fail with an
58-
// i/o timeout.
59-
"Network error on minPoolSize background creation": godriver2123SkipReason,
60-
"CreateCollection from encryptedFields.": godriver2413SkipReason,
61-
"DropCollection from encryptedFields": godriver2413SkipReason,
62-
"DropCollection from remote encryptedFields": godriver2413SkipReason,
54+
"operation fails with maxWireVersion < 8": spec1403SkipReason,
55+
"CreateCollection from encryptedFields.": godriver2413SkipReason,
56+
"DropCollection from encryptedFields": godriver2413SkipReason,
57+
"DropCollection from remote encryptedFields": godriver2413SkipReason,
6358
}
6459
)
6560

mongo/options/clientoptions.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,7 @@ func (c *ClientOptions) validate() error {
315315
// Direct connections cannot be made if multiple hosts are specified or an SRV URI is used.
316316
if c.Direct != nil && *c.Direct {
317317
if len(c.Hosts) > 1 {
318-
return errors.New("a direct connection cannot be made if multiple hosts are specified")
318+
return fmt.Errorf("a direct connection cannot be made if multiple hosts are specified: %v", c.Hosts)
319319
}
320320
if c.cs != nil && c.cs.Scheme == connstring.SchemeMongoDBSRV {
321321
return errors.New("a direct connection cannot be made if an SRV URI is used")

mongo/options/clientoptions_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,7 @@ func TestClientOptions(t *testing.T) {
600600
})
601601
t.Run("direct connection validation", func(t *testing.T) {
602602
t.Run("multiple hosts", func(t *testing.T) {
603-
expectedErr := errors.New("a direct connection cannot be made if multiple hosts are specified")
603+
expectedErr := errors.New("a direct connection cannot be made if multiple hosts are specified: [localhost localhost2]")
604604

605605
testCases := []struct {
606606
name string

0 commit comments

Comments
 (0)