Config Tips - YaleSTC/reservations GitHub Wiki
Development
-
Can't start your
rails s
due to an execjs runtime error? Make suretherubyracer
is uncommented out in your gemfile. -
CSS or javascript changes no longer autoloading in development? Rails will serve assets if it finds preexisting files in the pipeline. Try
rake assets:clean
Production
- No css or javascript in production mode? Run
RAILS_ENV=production rake assets:precompile
and make sureconfig/environments/production.rb
lineconfig.serve_static_assets
is set totrue
. Webservers serve static assets automatically but when 'testing' production make sure to set this manually.
Testing
- Suddenly all the tests are failing?
RAILS_ENV=test rake db:drop && rake db:create && rake db:migrate
- Alternatively to the above, you can set your recurring test task to be
rake db:test:prepare && rspec