Files
app/tests/export.test.ts
zooqueenandHanzo Dev 91da549471 feat(app): scaffold lux cross-platform app (Expo+Tauri) on @hanzo/gui
Phase 1: rebranded @hanzogui/expo-router-starter as @luxfi/app. Targets iOS/Android/web
(Expo) + desktop (Tauri). Drives luxfi/node + luxfi/ai. See README.

Co-authored-by: Hanzo Dev <[email protected]>
2026-06-01 23:30:05 -07:00

32 lines
1.0 KiB
TypeScript

import { expect, test } from '@playwright/test'
test('static export hydrates without Missing theme error', async ({ page }) => {
const errors: string[] = []
page.on('pageerror', (err) => {
errors.push(err.message)
})
await page.goto('/', { waitUntil: 'load' })
// wait for client hydration
await page.waitForTimeout(3000)
// should not show the error boundary
await expect(page.getByText('Something went wrong')).not.toBeVisible()
await expect(page.getByText('Missing theme')).not.toBeVisible()
// verify gui rendered with theme - the heading should be visible
const heading = page.getByText('Gui + Expo')
await expect(heading).toBeVisible()
// verify no page errors related to missing theme
const themeErrors = errors.filter((e) => e.includes('Missing theme'))
expect(themeErrors).toHaveLength(0)
// verify themed styles are applied (not unstyled)
const color = await heading.evaluate((el) => window.getComputedStyle(el).color)
expect(color).toBeTruthy()
expect(color).not.toBe('')
})