diff options
author | David Gay <david@davidgay.org> | 2021-04-06 20:01:27 -0400 |
---|---|---|
committer | David Gay <david@davidgay.org> | 2021-04-06 20:01:27 -0400 |
commit | bf4912554058164fabd410b3082b6aa53e7ed026 (patch) | |
tree | 24548647d3b6de7b7287dbe90958ee3eda9c665d /test | |
parent | 1d3c909a2fe818935afc7b4b60ea31c2cf3852fd (diff) |
PTU frequencies
Diffstat (limited to 'test')
-rw-r--r-- | test/fixtures/ptu_frequencies.yml | 7 | ||||
-rw-r--r-- | test/models/ptu_frequency_test.rb | 9 | ||||
-rw-r--r-- | test/models/ptu_type_test.rb | 2 |
3 files changed, 17 insertions, 1 deletions
diff --git a/test/fixtures/ptu_frequencies.yml b/test/fixtures/ptu_frequencies.yml new file mode 100644 index 0000000..771941d --- /dev/null +++ b/test/fixtures/ptu_frequencies.yml @@ -0,0 +1,7 @@ +# Read about fixtures at https://api.rubyonrails.org/classes/ActiveRecord/FixtureSet.html + +one: + name: At-Will + +two: + name: Scene diff --git a/test/models/ptu_frequency_test.rb b/test/models/ptu_frequency_test.rb new file mode 100644 index 0000000..5ebc48c --- /dev/null +++ b/test/models/ptu_frequency_test.rb @@ -0,0 +1,9 @@ +require "test_helper" + +class PtuFrequencyTest < ActiveSupport::TestCase + test "can create" do + assert_difference("PtuFrequency.count", 1) do + PtuFrequency.create(name: "Whenever") + end + end +end diff --git a/test/models/ptu_type_test.rb b/test/models/ptu_type_test.rb index f7666df..39bfcfc 100644 --- a/test/models/ptu_type_test.rb +++ b/test/models/ptu_type_test.rb @@ -1,7 +1,7 @@ require "test_helper" class PtuTypeTest < ActiveSupport::TestCase - test "can create type" do + test "can create" do assert_difference("PtuType.count", 1) do PtuType.create(name: "TestType") end |