a5c-ai/babysitter / library/specializations/desktop-development/skills/qt-test-fixture-generator
qt-test-fixture-generator
VerifiedGenerate Qt Test fixtures with mock QObject signals and slots, data-driven tests, and GUI testing setup
README.md
View on GitHub# qt-test-fixture-generator
Generate Qt Test fixtures with mock QObjects and data-driven tests.
## Overview
This skill creates comprehensive QTest-based test infrastructure including test fixtures, mock objects, data providers, and CMake integration.
## Quick Start
```javascript
const result = await invokeSkill('qt-test-fixture-generator', {
projectPath: '/path/to/qt-project',
classToTest: 'MyWidget',
testType: 'unit',
mockDependencies: ['DataService', 'NetworkManager'],
dataProviders: [
{
testName: 'testCalculation',
columns: ['input', 'expected'],
rows: [['10', '20'], ['0', '0'], ['-5', '-10']]
}
],
generateCoverage: true
});
```
## Features
### Test Types
| Type | Description |
|------|-------------|
| unit | Isolated class testing |
| integration | Component interaction |
| gui | Widget interaction testing |
| benchmark | Performance measurement |
### Generated Components
- Test class with lifecycle methods
- Mock objects with call tracking
- Data providers for parameterized tests
- CMake configuration
## Running Tests
```bash
# All tests
ctest --test-dir build
# Single test
./build/tests/tst_mywidget
# Specific function
./build/tests/tst_mywidget testSetValue
```
## Related Skills
- `qt-cmake-project-generator`
- `cross-platform-test-matrix`
## Related Agents
- `qt-cpp-specialist`
- `desktop-test-architect`
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 |