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/example-tests/ExampleAcceptanceCest.php
View on GitHub<?php
declare(strict_types=1);
namespace Vendor\Extension\Tests\Acceptance;
use Vendor\Extension\Tests\Acceptance\AcceptanceTester;
/**
* Example acceptance test demonstrating TYPO3 testing patterns
*
* Acceptance tests use a real browser to test complete user workflows.
* They verify frontend functionality and user interactions.
*/
final class LoginCest
{
public function _before(AcceptanceTester $I): void
{
// Runs before each test method
// Setup: Import fixtures, reset state, etc.
}
public function loginAsBackendUser(AcceptanceTester $I): void
{
// Navigate to login page
$I->amOnPage('/typo3');
// Fill login form
$I->fillField('username', 'admin');
$I->fillField('password', 'password');
// Submit form
$I->click('Login');
// Verify successful login
$I->see('Dashboard');
$I->seeInCurrentUrl('/typo3/module/dashboard');
}
public function loginFailsWithInvalidCredentials(AcceptanceTester $I): void
{
$I->amOnPage('/typo3');
$I->fillField('username', 'admin');
$I->fillField('password', 'wrong_password');
$I->click('Login');
// Verify login failed
$I->see('Login error');
$I->seeInCurrentUrl('/typo3');
}
public function searchesForProducts(AcceptanceTester $I): void
{
// Navigate to product listing
$I->amOnPage('/products');
// Wait for page to load
$I->waitForElement('.product-list', 5);
// Use search
$I->fillField('#search', 'laptop');
$I->click('Search');
// Wait for results
$I->waitForElement('.search-results', 5);
// Verify search results
$I->see('laptop', '.product-title');
$I->seeNumberOfElements('.product-item', [1, 10]);
}
public function addsProductToCart(AcceptanceTester $I): void
{
$I->amOnPage('/products/1');
// Click add to cart button
$I->click('#add-to-cart');
// Wait for AJAX response
$I->waitForElement('.cart-badge', 3);
// Verify cart updated
$I->see('1', '.cart-badge');
$I->see('Product added to cart');
}
}
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 |