Skip to content

Commit 988afae

Browse files
committed
test can use case insensitive dict
1 parent 6f705ba commit 988afae

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

test/test_uri_spec.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
from test import unittest
2828
from test.helpers import clear_warning_registry
2929

30-
from pymongo.common import INTERNAL_URI_OPTION_NAME_MAP, validate
30+
from pymongo.common import INTERNAL_URI_OPTION_NAME_MAP, _CaseInsensitiveDictionary, validate
3131
from pymongo.compression_support import _have_snappy
3232
from pymongo.synchronous.uri_parser import parse_uri
3333

@@ -169,7 +169,8 @@ def run_scenario(self):
169169
# Compare URI options.
170170
err_msg = "For option %s expected %s but got %s"
171171
if test["options"]:
172-
opts = options["options"]
172+
opts = _CaseInsensitiveDictionary()
173+
opts.update(options["options"])
173174
for opt in test["options"]:
174175
lopt = opt.lower()
175176
optname = INTERNAL_URI_OPTION_NAME_MAP.get(lopt, lopt)

0 commit comments

Comments
 (0)