IEEE.org     |     IEEE Xplore Digital Library     |     IEEE Standards     |     IEEE Spectrum     |     More Sites

Verified Commit 8c9917e9 authored by Emi Simpson's avatar Emi Simpson
Browse files

[new arch] Support comparing across arg list types

parent 6acc0e36
......@@ -43,7 +43,7 @@ class QueryRequest(NamedTuple):
def __eq__(self, other: object) -> bool:
if isinstance(other, QueryRequest):
return\
self.args == other.args and\
list(self.args) == list(other.args) and\
self._normalize_query_string(self.query) == self._normalize_query_string(other.query)
elif isinstance(other, Tuple):
return\
......
......@@ -57,6 +57,10 @@ class TestQueries(unittest.TestCase):
QueryRequest('part1,part2;', tuple()),
('part1 , part2', tuple())
)
self.assertEqual( # Test with differing arg lists
QueryRequest('aaa',(1, 2, 3)),
QueryRequest('aaa', [1, 2, 3])
)
def test_noop(self):
str_noop = Noop("hello")
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment