87 lines
3.5 KiB
Markdown
87 lines
3.5 KiB
Markdown
# Skill Assessment Quiz
|
|
|
|
This application manages quizzes intended to be used as pre-interview skill assessments.
|
|
|
|
## Development Guidelines
|
|
|
|
Please follow these guidelines as close as possible. Discuss and question them as needed.
|
|
|
|
* Run Guard while developing.
|
|
* `bundle exec guard`
|
|
* Always execute a full run before a push (simply hit return in your guard session).
|
|
* Honor RuboCop warnings.
|
|
* Write tests, And keep them green.
|
|
* Review the coverage report, keeping coverate > 90%.
|
|
* coverage/index.html
|
|
* It is OK to delete tests which are duplicated, or no longer relevant.
|
|
* If you find a bug, write a test to recreate it, so it never comes back unnoticed.
|
|
* Make sure to keep the fixture files current.
|
|
* `test/fixtures/*.yml`
|
|
* Include any new development data needs.
|
|
* Protect Gemfile.
|
|
* Does your new gem bring in a ton of unnecessary or outdated gems?
|
|
* Are you bringing in a gem that solves a problem already addressed by an existing gem?
|
|
* Do you really need this gem, or just a simple service object?
|
|
* Place your new gem appropriately. Some gem blocks are order specific, but most are alphabetized.
|
|
* Keep git comment subjects short, and use git comment bodies for more details.
|
|
* Pull with --rebase.
|
|
* `git config --global pull.rebase true`
|
|
* Feature branches are nice.
|
|
* Rebase feature branches onto develop before merging.
|
|
* `push -f` is ok on feature branches. Just communicate with others using that branch.
|
|
* Never merge develop _down_ to a feature branch.
|
|
* Merge with `--no-ff` when appropriate, `--squash` "WIP" commits into a complete thought.
|
|
* Clean up your remote branches after merge.
|
|
* Keep code comments to a minimum.
|
|
* We use git. Write a good commit message instead.
|
|
* Remove/Update code comments when changes are made.
|
|
* Leave the code better than you found it.
|
|
* Have fun.
|
|
|
|
## Setup
|
|
* clone
|
|
* checkout develop
|
|
* bundle
|
|
* npm install
|
|
* bower install
|
|
* cp config/application.yml.sample config/application.yml
|
|
* edit and update proper values to application.yml
|
|
* rake db:setup
|
|
* rake db:migrate
|
|
* rake db:fixtures:load
|
|
* `./rebuild-dev-db.sh` is a convenience script to rebuild and refresh your dev db with the fixture data.
|
|
|
|
## Docker
|
|
|
|
You can develop in this app with a native rails install, if you prefer.
|
|
However, there is also a docker image setup if you do not want to install all the supporting gems and libraries.
|
|
Please note: The guard watch session does not run all watches correctly in the docker container. The only issue this causes is all the automation is not 100%. Simply manually kick off the runners occasionally by hitting return in the session.
|
|
|
|
To use the docker container, you need to install and launch docker, which can be found here:
|
|
https://www.docker.com/products/docker
|
|
|
|
Once the container is started, you can still edit files from your host project directory.
|
|
|
|
visit http://localhost:3000 like normal
|
|
|
|
There are some convenience scripts included to make starting the container and rails app easier.
|
|
|
|
#### `./start-docker.sh`
|
|
* Execute from terminal, on the host machine, in the project directory
|
|
- This will pull the image from dockerhub, if needed
|
|
- Create and start up container
|
|
|
|
#### Once in the container:
|
|
* `./start-dev.sh`
|
|
* will spin up a dev session with tmux
|
|
* `./start-server.sh`
|
|
- starts up just rails server for viewing application
|
|
|
|
|
|
## TODOs and notes
|
|
|
|
* Question attachment path: http://dev.perficientxd.com/skill_assets/
|
|
* clean code
|
|
* [Confident Ruby](http://www.confidentruby.com/)
|
|
* [POODR](http://www.poodr.com/)
|