This directory contains CI/CD workflows and test fixtures for the Autoloader Coordinator project.
Comprehensive integration testing workflow that:
- Tests version resolution across 5 scenarios
- Tests WordPress/PHP compatibility
- Posts PR comments with test results
- Validates plugin activation and registration
Jobs:
version-resolution-test- Tests all version conflict scenarioswp-compatibility-test- Tests WordPress/PHP compatibilitypr-comment-on-failure- Posts warning comment on failurepr-comment-on-success- Posts success comment on pass
Test fixtures for version conflict scenarios. Each scenario contains:
plugin-a/composer.json- Plugin A's package versionplugin-a/php/functions.php- Plugin A's helper functionsplugin-b/composer.json- Plugin B's package versionplugin-b/php/functions.php- Plugin B's helper functions
Scenarios:
plugin-a-newer- Plugin A has newer versionplugin-b-newer- Plugin B has newer versionsame-version- Both have same versionmajor-version-diff- Major version differencepatch-version-diff- Patch version difference
- Create directory:
.github/fixtures/scenarios/[scenario-name]/ - Add
composer.jsonandphp/functions.phpfor each plugin - Add scenario to matrix in
wp-env-integration.yml - Update documentation
Tests that the coordinator correctly resolves version conflicts:
- Installs fixtures for scenario
- Sets up wp-env
- Activates plugins
- Verifies coordinator loads
- Tests version resolution
- Validates homepage rendering
Tests compatibility across WordPress/PHP versions:
- Tests on WordPress latest, 6.5, 6.4, 6.3
- Tests on PHP 8.2, 8.1, 7.4
- Validates coordinator works on all combinations
Automatically posts comments on pull requests:
- On Failure: Shows which tests failed and possible causes
- On Success: Shows all passing tests and coverage
To test workflows locally:
# Install act (GitHub Actions local runner)
brew install act # macOS
# or download from https://github.com/nektos/act
# Run workflow
act -W .github/workflows/wp-env-integration.ymlNote: Local testing may require Docker and may not fully replicate CI environment.
- Check workflow logs in GitHub Actions
- Review error messages in failed steps
- Test scenario locally with wp-env
- Verify fixture files are correct
- Check WordPress/PHP version compatibility
Helper functions missing:
- Verify Composer autoload files are generated
- Check
functions.phpis in autoload_files.php - Ensure fixtures are installed correctly
Version resolution incorrect:
- Verify fixture versions match expected
- Check plugin registration is working
- Clear coordinator cache
wp-env not ready:
- Increase wait timeout
- Check Docker is running
- Review wp-env logs