Skip to content

Commit 36b8246

Browse files
committed
[Issue #439] skip unsupported tests in 9.5 (tests with backups from replica and with pg_control_checkpoint() calling)
1 parent fc1bef8 commit 36b8246

File tree

2 files changed

+44
-16
lines changed

2 files changed

+44
-16
lines changed

.travis.yml

+16-15
Original file line numberDiff line numberDiff line change
@@ -26,21 +26,22 @@ notifications:
2626

2727
# Default MODE is basic, i.e. all tests with PG_PROBACKUP_TEST_BASIC=ON
2828
env:
29-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE
30-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=archive
31-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=backup
32-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=compression
33-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=delta
34-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=locking
35-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=merge
36-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=page
37-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=replica
38-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=retention
39-
- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=restore
40-
- PG_VERSION=11 PG_BRANCH=REL_11_STABLE
41-
- PG_VERSION=10 PG_BRANCH=REL_10_STABLE
42-
- PG_VERSION=9.6 PG_BRANCH=REL9_6_STABLE
43-
- PG_VERSION=9.5 PG_BRANCH=REL9_5_STABLE
29+
- PG_VERSION=9.5 PG_BRANCH=REL9_5_STABLE MODE=archive
30+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE
31+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=archive
32+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=backup
33+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=compression
34+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=delta
35+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=locking
36+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=merge
37+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=page
38+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=replica
39+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=retention
40+
#- PG_VERSION=12 PG_BRANCH=REL_12_STABLE MODE=restore
41+
#- PG_VERSION=11 PG_BRANCH=REL_11_STABLE
42+
#- PG_VERSION=10 PG_BRANCH=REL_10_STABLE
43+
#- PG_VERSION=9.6 PG_BRANCH=REL9_6_STABLE
44+
#- PG_VERSION=9.5 PG_BRANCH=REL9_5_STABLE
4445

4546
jobs:
4647
allow_failures:

tests/archive.py

+28-1
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,12 @@ def test_pgpro434_2(self):
8383
pg_options={
8484
'checkpoint_timeout': '30s'}
8585
)
86+
87+
if self.get_version(node) < self.version_to_num('9.6.0'):
88+
self.del_test_dir(module_name, fname)
89+
return unittest.skip(
90+
'Skipped because pg_control_checkpoint() is not supported in PG 9.5')
91+
8692
self.init_pb(backup_dir)
8793
self.add_instance(backup_dir, 'node', node)
8894
self.set_archiving(backup_dir, 'node', node)
@@ -698,6 +704,11 @@ def test_replica_archive(self):
698704
'checkpoint_timeout': '30s',
699705
'max_wal_size': '32MB'})
700706

707+
if self.get_version(master) < self.version_to_num('9.6.0'):
708+
self.del_test_dir(module_name, fname)
709+
return unittest.skip(
710+
'Skipped because backup from replica is not supported in PG 9.5')
711+
701712
self.init_pb(backup_dir)
702713
# ADD INSTANCE 'MASTER'
703714
self.add_instance(backup_dir, 'master', master)
@@ -823,6 +834,12 @@ def test_master_and_replica_parallel_archiving(self):
823834
pg_options={
824835
'archive_timeout': '10s'}
825836
)
837+
838+
if self.get_version(master) < self.version_to_num('9.6.0'):
839+
self.del_test_dir(module_name, fname)
840+
return unittest.skip(
841+
'Skipped because backup from replica is not supported in PG 9.5')
842+
826843
replica = self.make_simple_node(
827844
base_dir=os.path.join(module_name, fname, 'replica'))
828845
replica.cleanup()
@@ -911,6 +928,11 @@ def test_basic_master_and_replica_concurrent_archiving(self):
911928
'autovacuum': 'off',
912929
'archive_timeout': '10s'})
913930

931+
if self.get_version(master) < self.version_to_num('9.6.0'):
932+
self.del_test_dir(module_name, fname)
933+
return unittest.skip(
934+
'Skipped because backup from replica is not supported in PG 9.5')
935+
914936
replica = self.make_simple_node(
915937
base_dir=os.path.join(module_name, fname, 'replica'))
916938
replica.cleanup()
@@ -1932,6 +1954,11 @@ def test_archive_pg_receivexlog_partial_handling(self):
19321954
initdb_params=['--data-checksums'],
19331955
pg_options={'archive_timeout': '10s'})
19341956

1957+
if self.get_version(node) < self.version_to_num('9.6.0'):
1958+
self.del_test_dir(module_name, fname)
1959+
return unittest.skip(
1960+
'Skipped because backup from replica is not supported in PG 9.5')
1961+
19351962
self.init_pb(backup_dir)
19361963
self.add_instance(backup_dir, 'node', node)
19371964

@@ -2502,4 +2529,4 @@ def test_archive_show_partial_files_handling(self):
25022529
#t2 ----------------
25032530
# /
25042531
#t1 -A--------
2505-
#
2532+
#

0 commit comments

Comments
 (0)