Imported from seifertd/chord-practice (
AGENTS.md). Install upstream withnpx skills add seifertd/chord-practice. Copyright stays with the author.
Agent Instructions
Testing
- All new features and bug fixes must be accompanied by tests.
- Run
bin/rails testbefore committing — all tests must pass. - Controller tests go in
test/controllers/, model tests intest/models/. - To authenticate a player in controller tests, set
cookies[:player_id] = player.uuidinsetup— this uses the anonymous auth fallback inAuthentication#resume_sessionwithout requiring a real login session. - Fixtures use a pre-hashed password (
$2a$12$dUE8mqkdZdQLjm7etdI7UuctpetWmq9zAluJLPC3ShchYiGf3Zpmm) which corresponds to the plaintextpassword.
Migrations
- Always commit
db/schema.rbalongside any migration file. - Backfill data in the migration where possible, using raw SQL via
update_allrather than Ruby-level attribute assignment to avoid column cache issues.
General
- Run tests before pushing. Do not push a branch with failing tests.