From c5475c3a2d223a2258cf391e27b8c03e6a81f046 Mon Sep 17 00:00:00 2001 From: Evan Rusackas Date: Wed, 22 Apr 2026 12:39:25 -0700 Subject: [PATCH] address review: strip trailing slash in cache-warmup test expectations MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit get_dash_url() now rstrips the trailing slash from WEBDRIVER_BASEURL, so the test expectations need the same treatment — otherwise a baseurl that ends in / produces double-slash URLs that no longer match strategy output. Fixes both test_top_n_dashboards_strategy and test_dashboard_tags_strategy. Co-Authored-By: Claude Opus 4.7 --- tests/integration_tests/strategy_tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/integration_tests/strategy_tests.py b/tests/integration_tests/strategy_tests.py index 1cbd4b07a32..453a8ccca3d 100644 --- a/tests/integration_tests/strategy_tests.py +++ b/tests/integration_tests/strategy_tests.py @@ -83,7 +83,7 @@ class TestCacheWarmUp(SupersetTestCase): strategy = TopNDashboardsStrategy(1) result = sorted(strategy.get_urls()) - expected = sorted([f"{get_url_host()}{dash.url}"]) + expected = sorted([f"{get_url_host().rstrip('/')}{dash.url}"]) assert result == expected def reset_tag(self, tag): @@ -109,7 +109,7 @@ class TestCacheWarmUp(SupersetTestCase): # tag dashboard 'births' with `tag1` tag1 = get_tag("tag1", db.session, TagType.custom) dash = self.get_dash_by_slug("births") - tag1_urls = [f"{get_url_host()}{dash.url}"] + tag1_urls = [f"{get_url_host().rstrip('/')}{dash.url}"] tagged_object = TaggedObject( tag_id=tag1.id, object_id=dash.id, object_type=ObjectType.dashboard )