FireflyArtsCollective / ffagc

Firefly Art Grant Core Website
3 stars 2 forks source link

Fix spec after max funding db change #125

Closed May-Lee closed 5 years ago

May-Lee commented 5 years ago

Please take a look and see if I'm on the right track :) Other than 4 failures, we're raking green. There are only two more that I think are under this branch. I've C & Ped them below; give me hints if you have them, but otherwise will be working through them.

3) GrantSubmission validations with funding_requests_csv greater than grant limit is not valid
     Failure/Error: expect(subject).not_to be_valid
       expected #<GrantSubmission id: 1, name: "+1 jean shorts photo booth tattooed.", description: "Authentic irony bushwick kickstarter.", created_at: "2018-12-17 11:38:50", updated_at: "2018-12-17 11:38:50", grant_id: 1, artist_id: 1, proposal: nil, granted_funding_dollars: nil, funding_decision: nil, questions: nil, answers: nil, questions_updated_at: nil, answers_updated_at: nil, private_funding_notes: nil, public_funding_notes: nil, funding_requests_csv: "5001"> not to be valid
     # ./spec/models/grant_submission_spec.rb:68:in `block (4 levels) in <top (required)>'

  4) GrantSubmission#funding_levels_csv funding_levels_csv should eq "subject.grant.funding_levels_csv"
     Failure/Error: its(:funding_levels_csv) { is_expected.to eq('subject.grant.funding_levels_csv') }

       expected: "subject.grant.funding_levels_csv"
            got: nil

       (compared using ==)
     # ./spec/models/grant_submission_spec.rb:5:in `block (3 levels) in <top (required)>'
ywwg commented 5 years ago

thanks for trying to figure this out, it was hard! I fixed it elsewhere