Skip test due to a bug in Shoulda Matchers 3

Skip test until bug is solved:
https://github.com/thoughtbot/shoulda-matchers/issues/814

It is also needed to use the new qualifier `ignoring_case_sensitivity`
to `validate_uniqueness_of` introduced in Shoulda Matchers 3.1.0
This commit is contained in:
Ana María Martínez Gómez 2018-09-16 00:43:36 +02:00 committed by Henne Vogelsang
parent d7dd85bcc0
commit b778459e17

View file

@ -27,7 +27,8 @@ describe Track do
it { is_expected.to validate_presence_of(:short_name) }
it { is_expected.to allow_value('My_track_name').for(:short_name) }
it { is_expected.to_not allow_value('My track name').for(:short_name) }
it { is_expected.to validate_uniqueness_of(:short_name).scoped_to(:program_id) }
# there is a bug: https://github.com/thoughtbot/shoulda-matchers/issues/814
# it { is_expected.to validate_uniqueness_of(:short_name).ignoring_case_sensitivity.scoped_to(:program) }
it { is_expected.to validate_presence_of(:state) }
it { is_expected.to validate_inclusion_of(:state).in_array(%w[new to_accept accepted confirmed to_reject rejected canceled withdrawn]) }
it { is_expected.to validate_inclusion_of(:cfp_active).in_array([true, false]) }