feat: add CI test workflow and commands tests (#147)

Testing infrastructure improvements:

1. Add GitHub Actions workflow (.github/workflows/test.yml)
   - Runs on push/PR to main
   - Installs deps, builds, runs tests
   - Blocks merging broken code

2. Add tests for commands.ts (src/core/commands.test.ts)
   - Tests parseCommand() with valid/invalid inputs
   - Tests case insensitivity
   - Tests COMMANDS array and HELP_TEXT

Now at 231 tests across 17 test files.

Written by Cameron ◯ Letta Code

"Test early, test often." - Software proverb
This commit is contained in:
Cameron
2026-02-04 17:13:18 -08:00
committed by GitHub
parent c8d55c8e84
commit 030a2b2bc5
2 changed files with 113 additions and 0 deletions

27
.github/workflows/test.yml vendored Normal file
View File

@@ -0,0 +1,27 @@
name: Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- name: Run tests
run: npm run test:run