Conversation
|
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a comprehensive fixture validation system for the CSS if() polyfill that uses Playwright to test CSS transformations in real browser environments. The system validates that polyfill-processed CSS produces the same visual results as expected output across multiple browsers and viewport sizes.
- Creates browser-based testing infrastructure using Playwright to validate CSS fixture pairs
- Adds automated validation for media queries, @supports queries, and computed style comparison
- Provides command-line tooling and documentation for running and managing fixture tests
Reviewed Changes
Copilot reviewed 5 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
test/fixtures-validation/fixture-validation.test.js |
Main test file implementing browser-based fixture validation with Playwright |
test/fixtures-validation/fixture-validation.playwright.config.js |
Playwright configuration for fixture validation tests |
scripts/validate-fixtures.js |
Command-line script for running fixture validation tests |
package.json |
Adds Playwright dependency and test:fixtures npm script |
docs/FIXTURE_VALIDATION.md |
Comprehensive documentation for the fixture validation system |
Comments suppressed due to low confidence (1)
test/fixtures-validation/fixture-validation.test.js:31
- [nitpick] Function name '_getFixturePairs' uses a leading underscore which typically indicates private/internal functions, but this convention isn't consistently applied elsewhere in the file. Consider renaming to 'getFixturePairs' or applying the convention consistently.
const _getFixturePairs = () => {
| const polyfillUmdJs = readFileSync(polyfillUmdPath, 'utf8'); | ||
|
|
||
| // Get all fixture pairs | ||
| const _getFixturePairs = () => { |
There was a problem hiding this comment.
The function '_getFixturePairs' is defined but never used in the test file. Consider removing it or implementing its usage if it was intended for fixture discovery.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…github.com/mfranzke/css-if-polyfill into 38-validate-fixtures-by-chromium-rendering
Description
Resolves #38
Type of Change
Testing
Checklist
Browser Testing
If applicable, please test in the following browsers:
Performance Impact
If this change affects performance:
Breaking Changes
If this introduces breaking changes, please describe:
Additional Notes
Any additional information that reviewers should know.