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

Commitc3d89c2

Browse files
committed
tests: minor fixes in module "archive"
1 parent6128225 commitc3d89c2

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

‎tests/archive.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -452,22 +452,23 @@ def test_archive_push_partial_file_exists(self):
452452
filename=filename_orig+'.partial'
453453
file=os.path.join(wals_dir,filename)
454454

455+
# emulate stale .partial file
455456
withopen(file,'a')asf:
456457
f.write(b"blahblah")
457458
f.flush()
458459
f.close()
459460

460461
self.switch_wal_segment(node)
461-
sleep(15)
462+
sleep(20)
462463

463464
# check that segment is archived
464465
ifself.archive_compress:
465466
filename_orig=filename_orig+'.gz'
466467

467468
file=os.path.join(wals_dir,filename_orig)
468-
469469
self.assertTrue(os.path.isfile(file))
470470

471+
# successful validate means that archive-push reused stale wal segment
471472
self.validate_pb(
472473
backup_dir,'node',
473474
options=['--recovery-target-xid={0}'.format(xid)])

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp