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
4 changes: 4 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,13 @@ jobs:

- uses: actions/configure-pages@v6

- name: Verify OpenAI domain challenge is in the build
run: cmp public/.well-known/openai-apps-challenge dist/.well-known/openai-apps-challenge

- uses: actions/upload-pages-artifact@v5
with:
path: dist
include-hidden-files: true

deploy:
needs: build
Expand Down
7 changes: 7 additions & 0 deletions scripts/app-docs.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,13 @@ const placements = {
"writer-book": "src/pages/apps/writer/chapters/index.astro"
};

test("The domain challenge is packaged into the Pages deployment", () => {
assert.match(read("public/.well-known/openai-apps-challenge"), /^[A-Za-z0-9_-]+\n$/);
const deployment = read(".github/workflows/deploy.yml");
assert.match(deployment, /cmp public\/\.well-known\/openai-apps-challenge dist\/\.well-known\/openai-apps-challenge/);
assert.match(deployment, /uses: actions\/upload-pages-artifact@v5\s+with:\s+path: dist\s+include-hidden-files: true/);
});

test("Reader and Writer are listed with live applications and local documentation", () => {
const catalogue = read("src/pages/apps/index.astro");
for (const app of ["reader", "writer"]) {
Expand Down
Loading