testgres 1.13.3__tar.gz → 1.13.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. {testgres-1.13.3/testgres.egg-info → testgres-1.13.4}/PKG-INFO +2 -2
  2. {testgres-1.13.3 → testgres-1.13.4}/README.md +1 -1
  3. {testgres-1.13.3 → testgres-1.13.4}/pyproject.toml +1 -1
  4. {testgres-1.13.3 → testgres-1.13.4}/src/node.py +7 -9
  5. {testgres-1.13.3 → testgres-1.13.4/testgres.egg-info}/PKG-INFO +2 -2
  6. {testgres-1.13.3 → testgres-1.13.4}/tests/test_testgres_common.py +16 -19
  7. {testgres-1.13.3 → testgres-1.13.4}/LICENSE +0 -0
  8. {testgres-1.13.3 → testgres-1.13.4}/setup.cfg +0 -0
  9. {testgres-1.13.3 → testgres-1.13.4}/src/__init__.py +0 -0
  10. {testgres-1.13.3 → testgres-1.13.4}/src/api.py +0 -0
  11. {testgres-1.13.3 → testgres-1.13.4}/src/backup.py +0 -0
  12. {testgres-1.13.3 → testgres-1.13.4}/src/cache.py +0 -0
  13. {testgres-1.13.3 → testgres-1.13.4}/src/config.py +0 -0
  14. {testgres-1.13.3 → testgres-1.13.4}/src/connection.py +0 -0
  15. {testgres-1.13.3 → testgres-1.13.4}/src/consts.py +0 -0
  16. {testgres-1.13.3 → testgres-1.13.4}/src/decorators.py +0 -0
  17. {testgres-1.13.3 → testgres-1.13.4}/src/defaults.py +0 -0
  18. {testgres-1.13.3 → testgres-1.13.4}/src/enums.py +0 -0
  19. {testgres-1.13.3 → testgres-1.13.4}/src/exceptions.py +0 -0
  20. {testgres-1.13.3 → testgres-1.13.4}/src/impl/port_manager__generic.py +0 -0
  21. {testgres-1.13.3 → testgres-1.13.4}/src/impl/port_manager__this_host.py +0 -0
  22. {testgres-1.13.3 → testgres-1.13.4}/src/logger.py +0 -0
  23. {testgres-1.13.3 → testgres-1.13.4}/src/node_app.py +0 -0
  24. {testgres-1.13.3 → testgres-1.13.4}/src/port_manager.py +0 -0
  25. {testgres-1.13.3 → testgres-1.13.4}/src/pubsub.py +0 -0
  26. {testgres-1.13.3 → testgres-1.13.4}/src/raise_error.py +0 -0
  27. {testgres-1.13.3 → testgres-1.13.4}/src/standby.py +0 -0
  28. {testgres-1.13.3 → testgres-1.13.4}/src/utils.py +0 -0
  29. {testgres-1.13.3 → testgres-1.13.4}/testgres.egg-info/SOURCES.txt +0 -0
  30. {testgres-1.13.3 → testgres-1.13.4}/testgres.egg-info/dependency_links.txt +0 -0
  31. {testgres-1.13.3 → testgres-1.13.4}/testgres.egg-info/requires.txt +0 -0
  32. {testgres-1.13.3 → testgres-1.13.4}/testgres.egg-info/top_level.txt +0 -0
  33. {testgres-1.13.3 → testgres-1.13.4}/tests/test_config.py +0 -0
  34. {testgres-1.13.3 → testgres-1.13.4}/tests/test_os_ops_common.py +0 -0
  35. {testgres-1.13.3 → testgres-1.13.4}/tests/test_os_ops_local.py +0 -0
  36. {testgres-1.13.3 → testgres-1.13.4}/tests/test_os_ops_remote.py +0 -0
  37. {testgres-1.13.3 → testgres-1.13.4}/tests/test_raise_error.py +0 -0
  38. {testgres-1.13.3 → testgres-1.13.4}/tests/test_testgres_local.py +0 -0
  39. {testgres-1.13.3 → testgres-1.13.4}/tests/test_testgres_remote.py +0 -0
  40. {testgres-1.13.3 → testgres-1.13.4}/tests/test_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: testgres
3
- Version: 1.13.3
3
+ Version: 1.13.4
4
4
  Summary: Testing utility for PostgreSQL and its extensions
5
5
  Author-email: Postgres Professional <testgres@postgrespro.ru>
6
6
  License: PostgreSQL
@@ -40,7 +40,7 @@ Dynamic: license-file
40
40
 
41
41
  # testgres
42
42
 
43
- Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.17 and newer.
43
+ Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.3 and newer.
44
44
 
45
45
  ## Installation
46
46
 
@@ -8,7 +8,7 @@
8
8
 
9
9
  # testgres
10
10
 
11
- Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.17 and newer.
11
+ Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.3 and newer.
12
12
 
13
13
  ## Installation
14
14
 
@@ -11,7 +11,7 @@ exclude = [".git", "__pycache__", "env", "venv"]
11
11
 
12
12
  [project]
13
13
  name = "testgres"
14
- version = "1.13.3"
14
+ version = "1.13.4"
15
15
 
16
16
  description = "Testing utility for PostgreSQL and its extensions"
17
17
  readme = "README.md"
@@ -2236,18 +2236,16 @@ class PostgresNode(object):
2236
2236
  assert cursor is not None
2237
2237
 
2238
2238
  try:
2239
- cursor.execute("SELECT t::text FROM {} as t".format(
2239
+ cursor.execute("SELECT SUM(hashtext(t::text)) FROM {} as t".format(
2240
2240
  __class__._delim_sql_ident(table)
2241
2241
  ))
2242
2242
 
2243
- while True:
2244
- row = cursor.fetchone()
2245
- if row is None:
2246
- break
2247
- assert type(row) in [list, tuple] # noqa: E721
2248
- assert len(row) == 1
2249
- sum += hash(row[0])
2250
- continue
2243
+ row = cursor.fetchone()
2244
+ assert row is not None
2245
+ assert type(row) in [list, tuple] # noqa: E721
2246
+ assert len(row) == 1
2247
+ v = row[0]
2248
+ sum += int(v if v is not None else 0)
2251
2249
  finally:
2252
2250
  cursor.close()
2253
2251
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: testgres
3
- Version: 1.13.3
3
+ Version: 1.13.4
4
4
  Summary: Testing utility for PostgreSQL and its extensions
5
5
  Author-email: Postgres Professional <testgres@postgrespro.ru>
6
6
  License: PostgreSQL
@@ -40,7 +40,7 @@ Dynamic: license-file
40
40
 
41
41
  # testgres
42
42
 
43
- Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.17 and newer.
43
+ Utility for orchestrating temporary PostgreSQL clusters in Python tests. Supports Python 3.7.3 and newer.
44
44
 
45
45
  ## Installation
46
46
 
@@ -2029,31 +2029,28 @@ class TestTestgresCommon:
2029
2029
 
2030
2030
  class tagTableChecksumTestData:
2031
2031
  record_count: int
2032
- checksum: int
2033
2032
 
2034
2033
  def __init__(
2035
2034
  self,
2036
2035
  record_count: int,
2037
- checksum: int
2038
2036
  ):
2039
2037
  assert type(record_count) == int # noqa: E721
2040
- assert type(checksum) == int # noqa: E721
2041
2038
  self.record_count = record_count # noqa: E721
2042
- self.checksum = checksum # noqa: E721
2043
2039
  return
2044
2040
 
2045
2041
  sm_TableCheckSumTestDatas = [
2046
- tagTableChecksumTestData(0, 0),
2047
- tagTableChecksumTestData(1, 4602640778579266704),
2048
- tagTableChecksumTestData(2, 0),
2049
- tagTableChecksumTestData(3, 0),
2050
- tagTableChecksumTestData(987, 0),
2051
- tagTableChecksumTestData(999, 0),
2052
- tagTableChecksumTestData(1000, 0),
2053
- tagTableChecksumTestData(1001, 0),
2054
- tagTableChecksumTestData(1999, 0),
2055
- tagTableChecksumTestData(19999, 0),
2056
- tagTableChecksumTestData(199999, 0),
2042
+ tagTableChecksumTestData(0),
2043
+ tagTableChecksumTestData(1),
2044
+ tagTableChecksumTestData(2),
2045
+ tagTableChecksumTestData(3),
2046
+ tagTableChecksumTestData(987),
2047
+ tagTableChecksumTestData(999),
2048
+ tagTableChecksumTestData(1000),
2049
+ tagTableChecksumTestData(1001),
2050
+ tagTableChecksumTestData(1999),
2051
+ tagTableChecksumTestData(19999),
2052
+ tagTableChecksumTestData(199999),
2053
+ tagTableChecksumTestData(1999999),
2057
2054
  ]
2058
2055
 
2059
2056
  @pytest.fixture(
@@ -2105,7 +2102,7 @@ class TestTestgresCommon:
2105
2102
 
2106
2103
  with cn.connection.cursor() as cursor:
2107
2104
  assert cursor is not None
2108
- cursor.execute("SELECT t::text FROM \"t\" as t;")
2105
+ cursor.execute("SELECT hashtext(t::text) FROM \"t\" as t;")
2109
2106
 
2110
2107
  checksum1 = 0
2111
2108
  record_count = 0
@@ -2116,7 +2113,7 @@ class TestTestgresCommon:
2116
2113
  assert type(row) in [list, tuple] # noqa: E721
2117
2114
  assert len(row) == 1
2118
2115
  record_count += 1
2119
- checksum1 += hash(row[0])
2116
+ checksum1 += int(row[0])
2120
2117
  pass
2121
2118
 
2122
2119
  assert record_count == table_checksum_test_data.record_count
@@ -2165,7 +2162,7 @@ class TestTestgresCommon:
2165
2162
 
2166
2163
  with cn.connection.cursor() as cursor:
2167
2164
  assert cursor is not None
2168
- cursor.execute("SELECT t::text FROM \"t\" as t;")
2165
+ cursor.execute("SELECT hashtext(t::text) FROM \"t\" as t;")
2169
2166
 
2170
2167
  checksum1 = 0
2171
2168
  record_count = 0
@@ -2176,7 +2173,7 @@ class TestTestgresCommon:
2176
2173
  assert type(row) in [list, tuple] # noqa: E721
2177
2174
  assert len(row) == 1
2178
2175
  record_count += 1
2179
- checksum1 += hash(row[0])
2176
+ checksum1 += int(row[0])
2180
2177
  pass
2181
2178
 
2182
2179
  assert record_count == table_checksum_test_data.record_count
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes