End-to-end test across the browsers.
bundle install
npm install
bundle exec rake bower:install
bundle exec puma -C config/puma.rb -d
bundle exec sidekiq -C config/sidekiq.yml -d
open http://localhost:3000/
The followings are optional, but make you happier with this application.
E2E Tester provides public API to automate your e2e test.
You can use the browsers of Browserstack through WebDriver.
As environment variables,
BROWSERSTACK_USERNAME=foo
BROWSERSTACK_PASSWORD=bar
Or in config/settings.local.yml
,
browserstack:
username: foo
password: bar
Then, run the rake task to update the browsers.
bundle exec rake browser:update:browserstack
To use ActiveAdmin for this application, you need to create admin user to sign in.
AdminUser.create!(name: 'Your Name', email: 'foo@example.com', password: 'password', password_confirmation: 'password')
Then, open the admin console in your browser and sign in as the user.
open http://localhost:3000/admin/
You can try the e2e tester without any settings with docker-compose.
cp .docker_env.sample .docker_env
docker-compose up
open http://$(docker-machine ip $machine):3000
You can use .docker_env
to set environment variables which you don't want to expose.
To run rspec
, rubocop
and brakeman
in order,
bundle exec rake
bundle exec rspec
open coverage/index.html # The test coverage will be collected automatically.
Run rubocop for the code regulation
bundle exec rubocop -D
bundle exec rubocop -D --auto-correct # To correct them automatically as much as possible
Run brakeman for static vulnerability scan.
bundle exec brakeman
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Copyright (c) 2014 Daisuke Taniwaki. See LICENSE for details.