Skip to content

Conversation

@Robdel12
Copy link
Contributor

@Robdel12 Robdel12 commented Jan 4, 2026

Summary

Introduces @vizzly-testing/ember package that enables visual regression testing in Ember.js projects using Testem and Playwright.

  • Custom Testem launcher that uses Playwright for browser control (supports Chromium, Firefox, WebKit)
  • vizzlySnapshot() helper for capturing screenshots in acceptance tests
  • Automatic viewport sizing and #ember-testing container expansion (captures just the app, not QUnit UI)
  • TDD server auto-discovery via .vizzly/server.json
  • Mobile viewport testing with customizable dimensions
  • Test app fixture for SDK development and verification

Architecture

Browser (Ember test)
    │
    │ fetch() to snapshot server
    ▼
Snapshot Server (Node.js)
    │
    │ Playwright screenshot
    │
    │ forward to TDD server
    ▼
Vizzly TDD Server
    │
    │ Compare, save baselines
    ▼
.vizzly/baselines/

Usage

// testem.cjs
const { configure } = require('@vizzly-testing/ember');

module.exports = configure({
  cwd: 'dist',
  test_page: 'tests/index.html?hidepassed',
  launch_in_ci: ['Chrome'],
});
// tests/acceptance/visual-test.js
import { vizzlySnapshot } from '@vizzly-testing/ember/test-support';

test('captures homepage', async function(assert) {
  await visit('/');
  await vizzlySnapshot('homepage');
  await vizzlySnapshot('homepage-mobile', { width: 375, height: 667 });
});

Test plan

  • Unit tests for testem-config and snapshot-server
  • Integration tests for launcher
  • E2E test with real Ember app (npm run test:ember in clients/ember)
  • Verified screenshots capture just the app content at correct viewport sizes

Introduces @vizzly-testing/ember package that enables visual regression
testing in Ember.js projects using Testem and Playwright.

Key features:
- Custom Testem launcher that uses Playwright for browser control
- vizzlySnapshot() helper for capturing screenshots in acceptance tests
- Automatic viewport sizing and #ember-testing container expansion
- Support for Chromium, Firefox, and WebKit browsers
- TDD server auto-discovery via .vizzly/server.json
- Mobile viewport testing with customizable dimensions

Architecture:
- Browser-side test helper sends requests to local snapshot server
- Snapshot server captures screenshots via Playwright CDP/BiDi
- Screenshots forwarded to Vizzly TDD server for comparison

Usage:
1. Wrap testem.js with configure() function
2. Import vizzlySnapshot from @vizzly-testing/ember/test-support
3. Run tests with vizzly tdd start && ember test
Adds a minimal Ember app for testing the @vizzly-testing/ember SDK
during development. Uses file:.. dependency to link to parent package.

Includes:
- Basic Ember app with Vite/Embroider setup
- Visual test demonstrating vizzlySnapshot() usage
- testem.cjs configured with Vizzly launchers
- npm run test:ember script for running E2E tests
@claude

This comment was marked as resolved.

Testem automatically appends the test URL to launcher args,
so we shouldn't include '<url>' in the args array. The source
code was correct but the tests were asserting the wrong behavior.
- Add 7 reusable components (Button, Card, Alert, Modal, FormField, DataTable, NavBar)
- Add 4 page templates (index, forms, components, long-page)
- Expand acceptance tests to 19 covering pages, viewports, element selectors
- Add 25 integration tests for component rendering
- Fix fullPage option to capture full scrollable content (not just viewport)
@Robdel12 Robdel12 merged commit ef8a406 into main Jan 4, 2026
19 of 20 checks passed
@Robdel12 Robdel12 deleted the feat/ember-sdk branch January 4, 2026 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants