netresearch/typo3-testing-skill / skills/typo3-testing
typo3-testing
FlaggedUse when reproducing defects as failing tests, testing template or rendered output changes, confirming changes on a running TYPO3 instance, or setting up TYPO3 extension tests: unit/functional/E2E, PHPUnit 11-13, mutation testing, final-class mocks (v14), CI matrix across TYPO3 12/13/14.3 LTS, typo3-ci-workflows meta-package, CI failures. Also: transaction rollback, worker crashes, competing requests, testing-framework setup, test matrix, integration/e2e testing, coverage, test generation.
assets/Build/playwright/tests/playwright/accessibility/modules.spec.ts
View on GitHub/**
* Accessibility Tests for TYPO3 Backend Modules
*
* Uses axe-core to verify WCAG 2.0/2.1 compliance at levels A and AA.
* Customize the modules array for your extension's routes.
*
* @see https://www.deque.com/axe/
*/
import { test, expect } from '@playwright/test';
import AxeBuilder from '@axe-core/playwright';
/**
* Define modules to test for accessibility
* Replace with your extension's module routes
*/
const modules = [
{ name: 'My Extension Module', route: 'module/web/myextension' },
// Add more modules as needed:
// { name: 'Settings', route: 'module/web/myextension/settings' },
];
for (const module of modules) {
test(`${module.name} has no accessibility violations`, async ({ page }) => {
// Navigate to module
await page.goto(module.route);
await page.waitForLoadState('networkidle');
// Run accessibility scan on the content iframe
const accessibilityScanResults = await new AxeBuilder({ page })
.include('#typo3-contentIframe')
// Disable rules that may produce false positives in TYPO3 backend
.disableRules(['color-contrast'])
.analyze();
// Assert no violations
expect(accessibilityScanResults.violations).toEqual([]);
});
}
test.describe('Accessibility - Additional Checks', () => {
test('module menu has proper ARIA attributes', async ({ page }) => {
await page.goto('/');
await page.waitForLoadState('networkidle');
// Check module menu accessibility
const moduleMenu = page.locator('#modulemenu');
await expect(moduleMenu).toHaveAttribute('role', 'navigation');
});
test('interactive elements are keyboard accessible', async ({ page }) => {
await page.goto('module/web/myextension');
await page.waitForLoadState('networkidle');
const contentFrame = page.frameLocator('#typo3-contentIframe');
// Tab through interactive elements
await page.keyboard.press('Tab');
// Verify focus is visible
const focusedElement = contentFrame.locator(':focus');
await expect(focusedElement).toBeVisible();
});
});
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |