Skip to content

Commit

Permalink
Using chattr to make file immutable
Browse files Browse the repository at this point in the history
  • Loading branch information
maniSHarma7575 committed May 5, 2024
1 parent 45aa5e4 commit 844d985
Showing 1 changed file with 1 addition and 0 deletions.
Expand Up @@ -26,6 +26,7 @@ def setup
def test_bad_connection
Dir.mktmpdir do |dir|
File.chmod(0x000, dir)
system("chattr -R +i #{dir}/")
db_path = File.join(dir, "_exist/db/-cinco-dog.sqlite3")
error = assert_raise ActiveRecord::NoDatabaseError do
connection = SQLite3Adapter.new(adapter: "sqlite3", database: db_path)
Expand Down

0 comments on commit 844d985

Please sign in to comment.