From c0733281c679671fb21b3864c914d439fd2a8c3b Mon Sep 17 00:00:00 2001 From: lena-larionova <54370747+lena-larionova@users.noreply.github.com> Date: Tue, 9 Aug 2022 10:05:05 -0700 Subject: [PATCH] Update smoke tests for new IA (#4213) update smoke tests for new IA --- app/moved_urls.yml | 1 + tests/install.test.js | 2 +- tests/seo.test.js | 6 +++--- tests/sidebar.test.js | 12 ++++++------ 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/app/moved_urls.yml b/app/moved_urls.yml index 42c160948b3b..2b9bab3614ae 100644 --- a/app/moved_urls.yml +++ b/app/moved_urls.yml @@ -1,2 +1,3 @@ --- /gateway-oss/VERSION/configuration/: "/gateway/VERSION/reference/configuration/" +/gateway/VERSION/install-and-run/rhel/: "/gateway/VERSION/kong-production/install-options/linux/rhel/" diff --git a/tests/install.test.js b/tests/install.test.js index 8e14fab59978..8e02f1b15f45 100644 --- a/tests/install.test.js +++ b/tests/install.test.js @@ -1,6 +1,6 @@ const { test, expect } = require("@playwright/test"); test("latest page contains a version", async ({ page }) => { - await page.goto("/gateway/latest/install-and-run/rhel/"); + await page.goto("/gateway/latest/kong-production/install-options/linux/rhel/"); await expect(page.locator(".codeblock").first()).not.toContainText("kong-enterprise-edition-.rpm"); }); diff --git a/tests/seo.test.js b/tests/seo.test.js index 0965cbaaf4de..d506de9dc8c2 100644 --- a/tests/seo.test.js +++ b/tests/seo.test.js @@ -16,8 +16,8 @@ test.describe("Canonical links", () => { { title: "contains a canonical link pointing to itself if it's the latest version", - src: "/gateway/latest/install-and-run/docker/", - href: "/gateway/latest/install-and-run/docker/", + src: "/gateway/latest/kong-production/install-options/helm/", + href: "/gateway/latest/kong-production/install-options/helm/", }, { title: @@ -153,7 +153,7 @@ test.describe("sitemap includes", () => { "/mesh/latest/", "/kubernetes-ingress-controller/latest/", "/deck/latest/", - "/gateway/latest/install-and-run/docker/", + "/gateway/latest/kong-production/install-options/helm/", "/mesh/latest/installation/ecs/", "/kubernetes-ingress-controller/latest/deployment/k4k8s/", "/deck/latest/installation/", diff --git a/tests/sidebar.test.js b/tests/sidebar.test.js index 22d8c338c3ff..7ae91fad1921 100644 --- a/tests/sidebar.test.js +++ b/tests/sidebar.test.js @@ -74,7 +74,7 @@ test.describe("Outdated version documentation", () => { await expect(await s.count()).toBe(1); await expect(await s.getAttribute("href")).toEqual( expect.stringMatching( - new RegExp(`^/gateway/latest/install-and-run/rhel/$`) + new RegExp(`^/gateway/latest/kong-production/install-options/linux/rhel/$`) ) ); }); @@ -106,7 +106,7 @@ test.describe("Sidebar section count", () => { { title: "Gateway Single Sourced", path: "/gateway/latest/", - count: 8, + count: 9, }, { title: "decK", @@ -127,8 +127,8 @@ test.describe("sidenav versions", () => { { title: "Root page links to /latest/", src: "/gateway/latest/", - link_text: "Installation Options", - expected_url: "/gateway/latest/install-and-run/", + link_text: "Supported Distributions", + expected_url: "/gateway/latest/kong-production/install-options/linux/os-support", }, { title: "Versioned root page links to the correct version", @@ -139,8 +139,8 @@ test.describe("sidenav versions", () => { { title: "Sub page links to latest", src: "/gateway/latest/admin-api/", - link_text: "Installation Options", - expected_url: "/gateway/latest/install-and-run/", + link_text: "Supported Distributions", + expected_url: "/gateway/latest/kong-production/install-options/linux/os-support", }, { title: "Versioned sub page links to the correct version",