diff --git a/test/models/application_test.rb b/test/models/application_test.rb index eac1b1d4be00569b54c7bbb960a58723abb7e10d..f959b7a8b0f457cc11eedd3b6f1e3e0639c85ef5 100644 --- a/test/models/application_test.rb +++ b/test/models/application_test.rb @@ -1,7 +1,7 @@ require 'test_helper' class ApplicationTest < ActiveSupport::TestCase - # test "the truth" do - # assert true - # end + should belong_to :user + should validate_presence_of(:domain) + should validate_presence_of(:application_id) end diff --git a/test/models/user_test.rb b/test/models/user_test.rb index bcf2ab2b5f92ecd06ccc124726256615508991d2..86e0c5ce438ad0e45dbb687c3fe9e4350ce7b1cf 100644 --- a/test/models/user_test.rb +++ b/test/models/user_test.rb @@ -51,6 +51,7 @@ class UserTest < ActiveSupport::TestCase should have_many :shares should have_many :follows should have_many :reviews + should have_many :applications test 'an user can follow another user' do john = users(:john)