From e0868d17e19383763720b0483fae85fd1880f78f Mon Sep 17 00:00:00 2001 From: Finn Date: Wed, 18 Dec 2024 16:11:25 +0000 Subject: [PATCH] Add a normal file before the test run otherwise all `add_file`s fail --- test/unit/git/git_version_test.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/unit/git/git_version_test.rb b/test/unit/git/git_version_test.rb index 99db3ea9f0..cf5ea29152 100644 --- a/test/unit/git/git_version_test.rb +++ b/test/unit/git/git_version_test.rb @@ -300,6 +300,10 @@ class GitVersionTest < ActiveSupport::TestCase assert v.commit.blank? assert_empty v.blobs + assert_nothing_raised do + v.add_file('normal_file', StringIO.new('blah')) + end + assert_raise(Git::InvalidPathException) do v.add_file('///', StringIO.new('blah')) end