Skip to content

Commit e6f9e9f

Browse files
Remove oss/ent_scylla_version params from xfail_scylla_version_lt
xfail_scylla_version_lt now takes a single scylla_version parameter instead of separate oss_scylla_version and ent_scylla_version params. The enterprise/OSS version branching logic is removed; the decorator simply compares the current version against the single provided version. Update all call sites accordingly.
1 parent 0842348 commit e6f9e9f

4 files changed

Lines changed: 8 additions & 13 deletions

File tree

tests/integration/__init__.py

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -687,29 +687,24 @@ def is_scylla_enterprise(version: Version) -> bool:
687687
return version > Version('2000.1.1')
688688

689689

690-
def xfail_scylla_version_lt(reason, oss_scylla_version, ent_scylla_version, *args, **kwargs):
690+
def xfail_scylla_version_lt(reason, scylla_version, *args, **kwargs):
691691
"""
692692
It is used to mark tests that are going to fail on certain scylla versions.
693693
:param reason: message to fail test with
694-
:param oss_scylla_version: str, oss version from which test supposed to succeed
695-
:param ent_scylla_version: str, enterprise version from which test supposed to succeed
694+
:param scylla_version: str, version from which test supposed to succeed
696695
"""
697696
if not (reason.startswith("scylladb/scylladb#") or reason.startswith("scylladb/scylla-enterprise#")):
698697
raise ValueError('reason should start with scylladb/scylladb#<issue-id> or scylladb/scylla-enterprise#<issue-id> to reference issue in scylla repo')
699698

700-
if not isinstance(ent_scylla_version, str):
701-
raise ValueError('ent_scylla_version should be a str')
699+
if not isinstance(scylla_version, str):
700+
raise ValueError('scylla_version should be a str')
702701

703702
if SCYLLA_VERSION is None:
704703
return pytest.mark.skipif(False, reason="It is just a NoOP Decor, should not skip anything")
705704

706705
current_version = Version(get_scylla_version(SCYLLA_VERSION))
707706

708-
if is_scylla_enterprise(current_version):
709-
return pytest.mark.xfail(current_version < Version(ent_scylla_version),
710-
reason=reason, *args, **kwargs)
711-
712-
return pytest.mark.xfail(current_version < Version(oss_scylla_version), reason=reason, *args, **kwargs)
707+
return pytest.mark.xfail(current_version < Version(scylla_version), reason=reason, *args, **kwargs)
713708

714709

715710
def skip_scylla_version_lt(reason, scylla_version):

tests/integration/standard/test_application_info.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def teardown_module():
2727

2828

2929
@xfail_scylla_version_lt(reason='scylladb/scylla-enterprise#5467 - system.client_options is not yet supported',
30-
oss_scylla_version="7.0", ent_scylla_version="2026.1.0")
30+
scylla_version="2026.1.0")
3131
class ApplicationInfoTest(unittest.TestCase):
3232
attribute_to_startup_key = {
3333
'application_name': 'APPLICATION_NAME',

tests/integration/standard/test_control_connection.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ def test_control_connection_port_discovery(self):
135135
assert 7000 == host.broadcast_port
136136

137137
@xfail_scylla_version_lt(reason='scylladb/scylladb#26992 - system.client_routes is not yet supported',
138-
oss_scylla_version="7.0", ent_scylla_version="2026.1.0")
138+
scylla_version="2026.1.0")
139139
def test_client_routes_change_event(self):
140140
cluster = TestCluster()
141141

tests/integration/standard/test_metadata.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1197,7 +1197,7 @@ def test_export_keyspace_schema_udts(self):
11971197

11981198
@greaterthancass21
11991199
@xfail_scylla_version_lt(reason='scylladb/scylladb#10707 - Column name in CREATE INDEX is not quoted',
1200-
oss_scylla_version="5.2", ent_scylla_version="2023.1.1")
1200+
scylla_version="2023.1.1")
12011201
def test_case_sensitivity(self):
12021202
"""
12031203
Test that names that need to be escaped in CREATE statements are

0 commit comments

Comments
 (0)