$ bundle install
$ bundle exec rake db:create
$ bundle exec rake db:migrate
$ bundle exec rake db:seed
$ bundle exec rails s
$ open http://localhost:3000To run acceptance tests chromedriver is required.
If using macOS and homebrew, you can install chromedriver with the following command:
$ brew cask install chromedriverTo run the full test suite:
$ bundle exec rakeIf you'd like to not run your tests headless, for example, to troubleshoot an issue and see what's on the screen, modify the driven_by driver in spec/support/system_test_configuration.rb to use :selenium_chrome instead of :selenium_chrome_headless. After the change, this block should look as follows:
config.before(:each, type: :system, js: true) do
driven_by :selenium_chrome
endThe application may be run via docker and docker-compose. Once installed run:
$ docker-compose buildTo run the application for the first time:
# Create the database
$ docker-compose run web rake db:setup
# Start the application
$ docker-compose upTo run rspec:
$ docker-compose run web bundle exec rspecOnce docker is running, type docker ps in the terminal and copy the ID of the theledger_web image.
Then, in a new terminal window, use the container ID you copied to open an image specific terminal...
$ docker attach COPIED_CONTAINER_IDLastly, set binding.pry in the usual fashion, and use the new image specific terminal to interact with your breakpoint.
After updating the gnar-style gem, you must take care to ensure that your local rubocop file does not stray from the update made to the gem in an unintended manner. Any changes in the local rubocop file will take precedence over what is in the gnar-style gem. See the gnar-style docs for more details.