empowerhack / DrawMyLife-Service

API and Admin system for the Draw My Life initiative - Volunteers: check README and GitHub Projects to get started.
https://github.com/empowerhack/DrawMyLife-Service/projects
MIT License
13 stars 0 forks source link

Add drawing#mood_rating validation to ensure between 1-5; #134

Closed mathildathompson closed 7 years ago

mathildathompson commented 7 years ago

Addresses issue: #129

What this does

Screenshots

image

Deploy Instructions

Rake tasks can be run by running:

bundle exec rake backfill:mood_rating_field

mathildathompson commented 7 years ago

@krissy please can you review when you have a chance :-)

steverabino commented 7 years ago

Will require an update to https://github.com/empowerhack/DrawMyLife-Service/blob/master/spec/models/drawing_spec.rb#L28 to fix that broken test

steverabino commented 7 years ago

Me and @krissy also spoke about whether the backfill rake task should be a database migration rather than a rake task - this would ensure that it is run when the code is updated on each environment, and also ensure that it is only ever run once on each environment

steverabino commented 7 years ago

@krissy @mathildathompson Can one or both of you take a peek and give a 👍 or 👎 on my commit made today? https://github.com/empowerhack/DrawMyLife-Service/pull/134/commits/f248c515bc75a2e3fe41d45fe52a42a1b8b1244e