Reagent creation and barcoding service for DNA Pipeline.
- Ruby 2.7.2
- MySQL 8.0
- Chrome (for testing)
- The gems in the
gemfileare separated into groups. When runningbundle install, you will not need the gems in thedeploymentgroup for working locally. In order to ignore thedeploymentgroup on install, run:
bundle config set without 'deployment'bundle install
-
Check the details in
database.ymlare correct for your local setup. By default the configuration expects a userrootwith nopasswordon the default MySQL port (3306). -
Initialise the test database:
RAILS_ENV=test rails db:create
RAILS_ENV=test rails db:schema:load- Run the tests
bundle exec rspec- Initialise the development database:
RAILS_ENV=development rails db:create
RAILS_ENV=development rails db:schema:load- Add the seed data
RAILS_ENV=development rails db:seed- Create a new team and add yourself as a user:
rails console
> team = Team.create(name: "Team Name")
> user = User.create(username: "YOUR_SANGER_USERNAME", team: team)
-
Run
rails serverand navigate to http://localhost:3000 -
Log in with your username and no password.
Mixtio in production uses the Sanger LDAP server to authenticate users. In development, this is stubbed out and any password for a valid user will successfully authenticate them.
To turn this feature off, set stub_ldap to false in development.rb.
- Trouble with
libv8andtherubyracer? Check out https://stackoverflow.com/a/55645176
- Testing: RSpec Rails
- Pagination: Kaminari
- Creating test data: Factory Girl
- For testing web interactions: Capybara