Skip to content

Commit

Permalink
using assert_not instead of refute
Browse files Browse the repository at this point in the history
  • Loading branch information
Rajarshi Das committed Aug 13, 2013
1 parent 620f41c commit 8910f12
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions activerecord/test/cases/adapters/postgresql/bytea_test.rb
Expand Up @@ -66,22 +66,22 @@ def test_read_nil_value
def test_write_value
data = "\u001F"
record = ByteaDataType.create(payload: data)
refute record.new_record?
assert_not record.new_record?
assert_equal(data, record.payload)
end

def test_write_binary
data = File.read(File.join(File.dirname(__FILE__), '..', '..', '..', 'assets', 'example.log'))
assert(data.size > 1)
record = ByteaDataType.create(payload: data)
refute record.new_record?
assert_not record.new_record?
assert_equal(data, record.payload)
assert_equal(data, ByteaDataType.where(id: record.id).first.payload)
end

def test_write_nil
record = ByteaDataType.create(payload: nil)
refute record.new_record?
assert_not record.new_record?
assert_equal(nil, record.payload)
assert_equal(nil, ByteaDataType.where(id: record.id).first.payload)
end
Expand Down
Expand Up @@ -406,7 +406,7 @@ def test_find_on_child_instance_with_id_should_not_load_all_child_records
interest = Interest.create!(man: man)

man.interests.find(interest.id)
refute man.interests.loaded?
assert_not man.interests.loaded?
end

def test_raise_record_not_found_error_when_invalid_ids_are_passed
Expand Down

0 comments on commit 8910f12

Please sign in to comment.