Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit fb411c8

Browse files
committed
check also insert_test checksum in tests
1 parent 9cbec06 commit fb411c8

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

tests/lib/bank_client.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ def create_extension(self):
150150

151151
def is_data_identic(self):
152152
hashes = set()
153+
hashes2 = set()
153154

154155
for dsn in self.dsns:
155156
con = psycopg2.connect(dsn)
@@ -160,11 +161,17 @@ def is_data_identic(self):
160161
from
161162
(select * from bank_test order by uid) t;""")
162163
hashes.add(cur.fetchone()[0])
164+
165+
cur.execute("""
166+
select md5(string_agg(id, ','))
167+
from (select id from insert_test order by id) t;""")
168+
hashes2.add(cur.fetchone()[0])
163169
cur.close()
164170
con.close()
165171

166172
print(hashes)
167-
return (len(hashes) == 1)
173+
print(hashes2)
174+
return (len(hashes) == 1 and len(hashes2) == 1)
168175

169176
def no_prepared_tx(self):
170177
n_prepared = 0

0 commit comments

Comments
 (0)