Skip to content

Commit

Permalink
Merge pull request #42001 from ricardotk002/fix-encrypted-fixtures-test
Browse files Browse the repository at this point in the history
Fix test `EncryptableFixtureTest` that fails intermittently
  • Loading branch information
kamipo committed Apr 17, 2021
2 parents 10f031f + edc481a commit 9a263e9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def name

# Only run for adapters that add a default string limit when not provided (MySQL, 255)
if EncryptedAuthor.columns_hash["name"].limit
# No column limits in SQLLite
# No column limits in SQLite
test "validate column sizes" do
assert EncryptedAuthor.new(name: "jorge").valid?
assert_not EncryptedAuthor.new(name: "a" * 256).valid?
Expand Down
2 changes: 2 additions & 0 deletions activerecord/test/cases/encryption/encrypted_fixtures_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
require "models/book_encrypted"

class ActiveRecord::Encryption::EncryptableFixtureTest < ActiveRecord::EncryptionTestCase
self.use_transactional_tests = false

fixtures :encrypted_books, :encrypted_book_that_ignores_cases

test "fixtures get encrypted automatically" do
Expand Down

0 comments on commit 9a263e9

Please sign in to comment.