Sha256: ae250a0639c44913e500be267eb8794a5da8db2f0753bbb0d7f30d4cef7715d3
Contents?: true
Size: 428 Bytes
Versions: 10
Compression:
Stored size: 428 Bytes
Contents
require_relative '../test_helper' class FooTest < ActiveSupport::TestCase def test_fixtures_validity Foo.all.each do |foo| assert foo.valid?, foo.errors.inspect end end def test_validation foo = Foo.new assert foo.invalid? assert_equal [:bar], foo.errors.keys end def test_creation assert_difference 'Foo.count' do Foo.create( bar: 'test bar', ) end end end
Version data entries
10 entries across 10 versions & 1 rubygems