-
Notifications
You must be signed in to change notification settings - Fork 66
Project Setup
Note: The following assumes you have a ruby development environment setup on your local machine.
- GitHub Account
- Git
- Ruby v2.2.2
- Rails 4.2.3
Forking the project creates a copy of the code base which you can modify without affecting the main code base. Once you are satisfied with your changes, you can make a pull request to the main repository.
Visit the project homepage on GitHub https://github.com/AgileVentures/MetPlus_PETS Fork the project by clicking the Fork button on the top-right hand corner. Wait while the repository is being forked. All done!
Now that you have a fork of the project, copy the URL for the repository (just below the sidebar on the right) and clone the project using Git:
$ cd to/some/directory
$ git clone https://github.com/<your-github-username>/MetPlus_PETS.git
You also need to configure remote to point to the main project repository in order to get latest updates. (This will be required at a later stage when submitting your features)
$ cd MetPlus_PETS
$ git remote add upstream https://github.com/AgileVentures/MetPlus_PETS.git
$ bundle install --without production
Sensitive or secret information (e.g. email server credentials) are maintained in this file:
config/application.yml
That file will not be present in the environment because it is not maintained in git and thus is not pulled down from github. Contact one of the project members to get the contents of that file (for example via private message in Slack).
$ bundle exec rake db:migrate
$ bundle exec rake db:seed
See "Note" below regarding subsequent updates to the database.
$ bundle exec rake spec
$ bundle exec rake cucumber
Discuss any errors with the team.
NOTE REGARDING FIREFOX FOR CUCUMBER TESTS: You will need firefox version 46.x or below for cucumber tests (that use javascript) to run successfully.
-
Download FF46.0.1 from here and extract the compressed firefox to a directory of your choice
-
include an environment variable called
FIREFOX_BINARY_PATH
in your.bashrc
file. The environmental will point to the directory where you placed the firefox executable:export FIREFOX_BINARY_PATH="/path/to/extracted/firefox"
This is a video of a pair programming session focused on configuring the correct firefox version in a Cloud9
$ bundle exec rails s
We use waffle (from Github) for issues and story tracking. To be added as a collaborator to waffle (so you can take ownership of a story, for example), please provide your Github user name to João Pereira on slack (joaopereira) and ask to be added as a collaborator.
- Updating the database - updates to the development DB (after the first described above) should be performed with this command:
rake db:drop db:migrate db:seed
This is because some of the migration files actually add records to the DB. These need to be present for the seeding to work. (that is, rake db:reset
will not work because it does not actually run the migration files, but simply reloads the DB schema from db/schema.rb).
You can find some solutions on this page