-
Notifications
You must be signed in to change notification settings - Fork 6
Development process
James Jefferies edited this page Aug 19, 2020
·
6 revisions
The basic development process is:
- Create a new local branch from
master
in git for the bug fix or new feature - Make the relevant code changes, adding rspec tests as required
- Check for any suggestions from the commit process (using overcommit)
- Push the code to the github repository and create a new pull request, assign to yourself
- Wait for the travis build to complete to confirm tests run successfully
- Also check for feedback from Code Climate and make any suggested changes as required
- Deploy to the test environment and tag with 'On test'
- Ask for feedback/review by adding a reviewer
- Once the reviewer has approved and everything is ok on test, then..
- Merge the pull request
Releases to production and test are currently done manually. See Hosting and deployment.
- Tests are implemented as rspec tests which can be found in the
spec
directory. - There's a mixture of approaches to setting up test data. We use FactoryGirl in some places, static
fixtures
in others - All system tests use
rspec
too, there are no Cucumber tests any more - Coverage reports are generated into the
coverage
directory automatically after running the tests
- The staging server at
test.energysparks.uk
is another ElasticBeanstalk AWS instance - It has a copy of production data, with some anonymisation
- It runs all of the usual data load jobs, content generation
The application uses standard Rails database migrations for database changes (don't use them for data migrations)
The application uses After Party for any data changes required (rather than having them in a database migration)
THe analytics code has traditionally been developed by the project energy expert. To do a proper analytics release you will need to do the following
- Check out the master branch (where generally the energy expert does their development)
- Update the version.rb file with the new version
- Once commited, create a tag with the same name as the new version and push to github.
- Update the Energy Sparks analytics version in the Gemfile
- Run bundle to update the Gemfile.lock file