diff options
author | Marius Peter <marius.peter@tutanota.com> | 2024-12-29 15:14:43 +0100 |
---|---|---|
committer | Marius Peter <marius.peter@tutanota.com> | 2024-12-29 15:14:43 +0100 |
commit | be2a93525069de2dfa3c23b0c23e7a9f7ad4c03d (patch) | |
tree | b5493e9d35d024ce7be072ec2168b4a98ba0e63f /test/models/scoring_criterium_test.rb |
First commit.
Diffstat (limited to 'test/models/scoring_criterium_test.rb')
-rw-r--r-- | test/models/scoring_criterium_test.rb | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/models/scoring_criterium_test.rb b/test/models/scoring_criterium_test.rb new file mode 100644 index 0000000..754e876 --- /dev/null +++ b/test/models/scoring_criterium_test.rb @@ -0,0 +1,21 @@ +require "test_helper" + +class ScoringCriteriumTest < ActiveSupport::TestCase + def setup + @scoring_criterium = scoring_criteria(:one) + end + + test "should be valid with valid attributes" do + assert @scoring_criterium.valid? + end + + test "should have category" do + @scoring_criterium.category = nil + assert_not @scoring_criterium.valid?, "Scoring Criterium has no category." + end + + test "should have name" do + @scoring_criterium.name = nil + assert_not @scoring_criterium.valid?, "Scoring Criterium has no name." + end +end |