Initial plugin scaffold: lesson scheduling WordPress plugin
Some checks failed
CI / Coding Standards (push) Failing after 2m31s
CI / PHPStan (push) Failing after 50s
CI / Tests (PHP 8.1) (push) Successful in 50s
CI / Tests (PHP 8.2) (push) Successful in 48s
CI / Tests (PHP 8.3) (push) Successful in 40s
CI / No Debug Code (push) Successful in 2s

- Custom DB tables for availability slots and lesson bookings
- Instructor (wp-admin) and student (front-end) roles with custom capabilities
- REST API under us-scheduler/v1 for availability CRUD and booking
- [us_booking] and [us_student_login] shortcodes for student front end
- PHPUnit + Brain\Monkey unit test suite (29 tests)
- Gitea Actions CI: lint, PHPStan, tests on PHP 8.1/8.2/8.3, no-debug check
- Feature docs under docs/features/

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-30 12:44:46 -03:00
commit 0fbafc9d18
41 changed files with 2249 additions and 0 deletions

102
.gitea/workflows/ci.yml Normal file
View File

@@ -0,0 +1,102 @@
name: CI
on:
push:
branches:
- main
- develop
pull_request:
jobs:
lint:
name: Coding Standards
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
tools: composer:v2
- name: Cache Composer packages
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: composer-${{ hashFiles('composer.json') }}
- name: Install dependencies
run: composer install --prefer-dist --no-progress --no-interaction
- name: Run PHPCS
run: composer cs
static-analysis:
name: PHPStan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
tools: composer:v2
- name: Cache Composer packages
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: composer-${{ hashFiles('composer.json') }}
- name: Install dependencies
run: composer install --prefer-dist --no-progress --no-interaction
- name: Run PHPStan
run: composer lint
test:
name: Tests (PHP ${{ matrix.php }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php:
- '8.1'
- '8.2'
- '8.3'
steps:
- uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, intl
coverage: none
tools: composer:v2
- name: Cache Composer packages
uses: actions/cache@v3
with:
path: ~/.composer/cache
key: ${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
- name: Install dependencies
run: composer install --prefer-dist --no-progress --no-interaction
- name: Run PHPUnit
run: composer test
no-debug:
name: No Debug Code
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check for debug statements
run: |
if grep -rn --include="*.php" -E "(var_dump|var_export|print_r|error_log|dd\(|dump\()" src/; then
echo "Debug code found in src/ — please remove before merging."
exit 1
fi