Skip to content

Commit 4fef1c0

Browse files
committed
python tests: forward-slash pg_waldump --path archive arguments on Windows
The pg_waldump basic test feeds --path the pgdata directory and, for the archive scenarios, the pg_wal.tar / pg_wal.tar.gz paths built with os.path.join (backslashes on Windows). pg_waldump splits the path on "/", so the backslash form made it fail to open the archive. Normalize the scenario path to forward slashes, matching the other WAL path fixes.
1 parent 79c213b commit 4fef1c0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/bin/pg_waldump/pyt/test_001_basic.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,8 @@ def test_pg_waldump_basic(pg_bin, create_pg, pg_config, tempdir_short):
428428
]
429429

430430
for scenario in scenarios:
431-
path = scenario["path"]
431+
# pg_waldump splits the path on "/", so feed it forward slashes.
432+
path = scenario["path"].replace("\\", "/")
432433

433434
if scenario["is_archive"] and (not tar):
434435
# skip "tar command is not available"

0 commit comments

Comments
 (0)