Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/auto-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ jobs:
with:
expected_sha: ${{ github.sha }}
target_env: live
pantheon_site_machine_name: documentation-in-nextjs
pantheon_site_machine_name: ${{ vars.PANTHEON_SITE_MACHINE_NAME }}
14 changes: 7 additions & 7 deletions .github/workflows/pr-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ jobs:
with:
expected_sha: ${{ github.event.pull_request.head.sha }}
target_env: pr-${{ github.event.pull_request.number }}
pantheon_site_machine_name: documentation-in-nextjs
pantheon_site_machine_name: ${{ vars.PANTHEON_SITE_MACHINE_NAME }}

- name: warm containers
id: warm_containers
shell: bash
env:
REFERENCE_BASE_URL: "https://dev-documentation-in-nextjs.pantheonsite.io"
DEPLOYED_BASE_URL: "https://pr-${{ github.event.pull_request.number }}-documentation-in-nextjs.pantheonsite.io"
REFERENCE_BASE_URL: "https://dev-${{ vars.PANTHEON_SITE_MACHINE_NAME }}.pantheonsite.io"
DEPLOYED_BASE_URL: "https://pr-${{ github.event.pull_request.number }}-${{ vars.PANTHEON_SITE_MACHINE_NAME }}.pantheonsite.io"
run: |
#!/bin/bash
set +e
Expand All @@ -54,7 +54,7 @@ jobs:
- name: Check all status codes
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
SITE_NAME: "documentation-in-nextjs"
SITE_NAME: "${{ vars.PANTHEON_SITE_MACHINE_NAME }}"
run: |
cd tests/404checking
export URL="https://pr-${PR_NUMBER}-${SITE_NAME}.pantheonsite.io"
Expand Down Expand Up @@ -86,8 +86,8 @@ jobs:
id: backstop_tests
shell: bash
env:
REFERENCE_BASE_URL: "https://dev-documentation-in-nextjs.pantheonsite.io"
DEPLOYED_BASE_URL: "https://pr-${{ github.event.pull_request.number }}-documentation-in-nextjs.pantheonsite.io"
REFERENCE_BASE_URL: "https://dev-${{ vars.PANTHEON_SITE_MACHINE_NAME }}.pantheonsite.io"
DEPLOYED_BASE_URL: "https://pr-${{ github.event.pull_request.number }}-${{ vars.PANTHEON_SITE_MACHINE_NAME }}.pantheonsite.io"
run: |
#!/bin/bash
set +e
Expand Down Expand Up @@ -125,7 +125,7 @@ jobs:
id: playwright_tests
shell: bash
env:
PLAYWRIGHT_DOMAIN: "pr-${{ github.event.pull_request.number }}-documentation-in-nextjs.pantheonsite.io"
PLAYWRIGHT_DOMAIN: "pr-${{ github.event.pull_request.number }}-${{ vars.PANTHEON_SITE_MACHINE_NAME }}.pantheonsite.io"
run: |
#!/bin/bash
set +e
Expand Down
2 changes: 1 addition & 1 deletion src/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ export function middleware(request: NextRequest) {
// This section handles the HTTP to HTTPS redirects for Pantheon sites.
// See https://github.com/pantheon-systems/documentation/issues/9791
// for more context.
const siteMachineName = "documentation-in-nextjs";
const siteMachineName = process.env.PANTHEON_SITE_MACHINE_NAME || "documentation-in-nextjs";
const incomingProtocol = request.headers.get('x-proto') || '';
const policyDocSurrogateKey = request.headers.get('policy-doc-surrogate-key') || '';
if (incomingProtocol === 'http://' && policyDocSurrogateKey) {
Expand Down
2 changes: 1 addition & 1 deletion tests/playwright/tests/search/search.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ test('searching from homepage redirects to search page and shows expected result

await page.waitForSelector('#results .addsearch-searchresults');

const expectedPolicyHeadline = ' Overages Policy | Traffic | Pantheon Docs';
const expectedPolicyHeadline = ' Overages Policy | Pantheon Docs';
const h3s1 = await page.locator('h3').allTextContents();
expect(h3s1.some(text => text.includes(expectedPolicyHeadline))).toBeTruthy();
});
Loading