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
14 changes: 12 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,20 @@ jobs:
- name: Install dependencies
run: npm ci

- name: Check website types
run: npm run check

- name: Install browser for website checks
run: npx playwright install --with-deps chromium

- name: Test website content and mobile layout
env:
BASE_PATH: ""
run: npx playwright test e2e/demo.test.ts --workers=1

- name: Build landing page
env:
NODE_ENV: production
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VITE_CTX_LOGIN_URL: ${{ secrets.VITE_CTX_LOGIN_URL }}
run: npm run build

Expand All @@ -60,4 +70,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
uses: actions/deploy-pages@v4
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,4 @@ ctx_config.json
.env

/.omc
test-results/
57 changes: 55 additions & 2 deletions e2e/demo.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,59 @@
import { expect, test } from '@playwright/test';

test('home page has expected h1', async ({ page }) => {
test('home page explains model-agnostic intelligence and paid Starter pricing', async ({
page
}) => {
await page.setViewportSize({ width: 1440, height: 1000 });
await page.goto('/');
await expect(page.locator('h1')).toBeVisible();
await expect(page.locator('h1')).toContainText('Codebase intelligence');
await expect(page.locator('.hero-subtitle')).toContainText('agents, IDEs, and any model');
await expect(
page.getByRole('heading', { name: 'Organization Knowledge', exact: true })
).toBeVisible();
await expect(
page.getByRole('heading', { name: 'Cross-Repo Intelligence', exact: true })
).toBeVisible();
const starter = page.locator('#pricing .feature-card').filter({
has: page.getByRole('heading', { name: 'Starter', exact: true })
});
await expect(starter).toContainText('$5');
await expect(starter).toContainText('$48/year');
await expect(starter).toContainText('2 repositories');
await expect(
page.getByRole('link', { name: 'Get started', exact: true }).first()
).toHaveAttribute('href', 'https://dev.context-engine.ai/auth/signup');
await expect(page.getByText(/start free|try for free|join the beta/i)).toHaveCount(0);
await expect(page.getByRole('link', { name: 'Helion DB ↗' })).toHaveAttribute(
'href',
'https://github.com/Context-Engine-AI/helion-db'
);
await expect(page.getByRole('link', { name: 'Context Engine Reviewer ↗' })).toHaveAttribute(
'href',
'https://github.com/Context-Engine-AI/Context-Engine-Reviewer'
);
await expect(page.getByRole('link', { name: 'Open VSX ↗', exact: true })).toHaveAttribute(
'href',
'https://open-vsx.org/extension/context-engine/context-engine-uploader'
);
await expect(page.getByText('BYOF — Bring Your Own Factory')).toBeVisible();
await expect(page.getByRole('link', { name: /Explore SWE-AF/ })).toHaveAttribute(
'href',
'https://github.com/Agent-Field/SWE-AF'
);
await page.screenshot({ path: 'test-results/paid-homepage-desktop.png', fullPage: true });
});

for (const width of [320, 390, 768]) {
test(`paid-plan homepage fits ${width}px and keeps signup accessible`, async ({ page }) => {
await page.setViewportSize({ width, height: 844 });
await page.goto('/');
await expect(
page.getByRole('link', { name: 'Get started', exact: true }).first()
).toBeVisible();
await expect(page.locator('#pricing')).toBeVisible();
expect(
await page.evaluate(() => document.documentElement.scrollWidth <= window.innerWidth)
).toBe(true);
await page.screenshot({ path: `test-results/paid-homepage-${width}.png`, fullPage: true });
});
}
Loading
Loading