Curated library of 28 atomic skills and 9 personas for Ruby on Rails development. Organized by category: testing, code-quality, engines, infrastructure, api, context, and personas. Covers code review, architecture, security, testing (RSpec), engines, Hotwire, and TDD automation. Shared Ruby skills (YARD docs, DDD, service objects) have moved to ruby-core-skills.
93
95%
Does it follow best practices?
Impact
93%
1.16xAverage score across 28 eval scenarios
Advisory
Suggest reviewing before use
Step-by-step guide for implementing authorization in Rails applications.
Add to Gemfile:
# For Pundit
gem 'pundit'
# For CanCanCan
gem 'cancancan'Run:
bundle installPundit:
rails g pundit:install
rails g pundit:policy PostCanCanCan:
rails g cancan:abilityDefine authorization logic in the generated file. See EXAMPLES.md for complete code samples.
Add authorization calls to controller actions:
def update
@post = Post.find(params[:id])
authorize @post # Pundit
# or
authorize! :update, @post # CanCanCan
# ...
endCreate policy specs and request specs covering all roles. See EXAMPLES.md for testing patterns.
Run all policy specs before deploying:
bundle exec rspec spec/policiesEnsure every role and edge case is explicitly covered.
After automated policy and request specs pass, attempt one denied action manually and record the result.
For Pundit, call Pundit.authorize so the denied exception is explicit:
Pundit.authorize(unauthorized_user, protected_record, :update?)
# raises Pundit::NotAuthorizedErrorFor CanCanCan, call authorize!:
Ability.new(unauthorized_user).authorize! :update, protected_record
# raises CanCan::AccessDeniedIf verifying through HTTP instead, record the request and the expected 403 Forbidden or app-specific denied-access response.
.tessl-plugin
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10
scenario-11
scenario-12
scenario-13
scenario-14
scenario-15
scenario-16
scenario-17
scenario-18
scenario-19
scenario-20
scenario-21
scenario-22
scenario-23
scenario-24
scenario-25
scenario-26
scenario-27
scenario-28
skills
api
generate-api-collection
implement-graphql
code-quality
apply-code-conventions
apply-stack-conventions
assets
snippets
code-review
refactor-code
review-architecture
security-check
context
load-context
setup-environment
engines
create-engine
create-engine-installer
document-engine
extract-engine
release-engine
review-engine
test-engine
upgrade-engine
infrastructure
implement-background-job
implement-hotwire
optimize-performance
review-migration
seed-database
version-api
personas
testing
plan-tests
test-service