mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-03-24 17:04:43 +00:00
config.load_defaults is now 7.1 and I had to add optional belongs to to a couple models as a deprecation from the 4.2 to 5.0 upgrade
This commit is contained in:
@@ -8,6 +8,6 @@ class MatTest < ActiveSupport::TestCase
|
||||
test "Mat validations" do
|
||||
mat = Mat.new
|
||||
assert_not mat.valid?
|
||||
assert_equal [:name], mat.errors.attribute_names
|
||||
assert_equal [:tournament, :name], mat.errors.attribute_names
|
||||
end
|
||||
end
|
||||
|
||||
@@ -8,6 +8,6 @@ class SchoolTest < ActiveSupport::TestCase
|
||||
test "School validations" do
|
||||
school = School.new
|
||||
assert_not school.valid?
|
||||
assert_equal [:name], school.errors.attribute_names
|
||||
assert_equal [:tournament,:name], school.errors.attribute_names
|
||||
end
|
||||
end
|
||||
|
||||
@@ -8,6 +8,6 @@ class WeightTest < ActiveSupport::TestCase
|
||||
test "Weight validations" do
|
||||
weight = Weight.new
|
||||
assert_not weight.valid?
|
||||
assert_equal [:max], weight.errors.attribute_names
|
||||
assert_equal [:tournament, :max], weight.errors.attribute_names
|
||||
end
|
||||
end
|
||||
|
||||
@@ -8,6 +8,6 @@ class WrestlerTest < ActiveSupport::TestCase
|
||||
test "Wrestler validations" do
|
||||
wrestler = Wrestler.new
|
||||
assert_not wrestler.valid?
|
||||
assert_equal [:name, :weight_id, :school_id], wrestler.errors.attribute_names
|
||||
assert_equal [:school, :weight, :name, :weight_id, :school_id], wrestler.errors.attribute_names
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user