Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7b587f7

Browse files
committed
[PBCKP-423] and again
1 parentcf10582 commit7b587f7

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

‎tests/archive_test.py‎

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1898,7 +1898,7 @@ def test_archive_push_sanity(self):
18981898
self.backup_node(backup_dir,'node',node)
18991899

19001900
withopen(os.path.join(node.logs_dir,'postgresql.log'),'r')asf:
1901-
postgres_log_content=f.read()
1901+
postgres_log_content=cleanup_ptrack(f.read())
19021902

19031903
# print(postgres_log_content)
19041904
# make sure that .backup file is not compressed
@@ -1927,14 +1927,7 @@ def test_archive_push_sanity(self):
19271927
replica.pgbench_init(scale=10)
19281928

19291929
withopen(os.path.join(replica.logs_dir,'postgresql.log'),'r')asf:
1930-
replica_log_content=f.read()
1931-
1932-
# PBCKP-423 - need to clean ptrack warning
1933-
ptrack_is_not='Ptrack 1.X is not supported anymore'
1934-
ifptrack_is_notinreplica_log_content:
1935-
lines= [lineforlineinreplica_log_content.splitlines()
1936-
ifptrack_is_notnotinline]
1937-
replica_log_content="".join(lines)
1930+
replica_log_content=cleanup_ptrack(f.read())
19381931

19391932
# make sure that .partial file is not compressed
19401933
self.assertNotIn('.partial.gz',replica_log_content)
@@ -2519,6 +2512,15 @@ def test_archive_empty_history_file(self):
25192512
'WARNING: History file is corrupted or missing: "{0}"'.format(os.path.join(wal_dir,'00000004.history')),
25202513
log_content)
25212514

2515+
defcleanup_ptrack(log_content):
2516+
# PBCKP-423 - need to clean ptrack warning
2517+
ptrack_is_not='Ptrack 1.X is not supported anymore'
2518+
ifptrack_is_notinlog_content:
2519+
lines= [lineforlineinlog_content.splitlines()
2520+
ifptrack_is_notnotinline]
2521+
log_content="".join(lines)
2522+
returnlog_content
2523+
25222524
# TODO test with multiple not archived segments.
25232525
# TODO corrupted file in archive.
25242526

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp