aboutsummaryrefslogtreecommitdiff
path: root/t/t9300-fast-import.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-03-26 12:10:25 -0700
committerJunio C Hamano <gitster@pobox.com>2012-03-26 12:10:25 -0700
commit79efeae69d843af575fb27696f5263fe76c570a6 (patch)
tree91323d37d30cdf47dec3a2a9ef88933ac7f495e6 /t/t9300-fast-import.sh
parentbda02ebc39fc9e46c979eee8026a66ac1a060dbd (diff)
parent178e1deaae33f879ea687e85ac72455b3072b0d8 (diff)
downloadgit-79efeae69d843af575fb27696f5263fe76c570a6.tar.gz
git-79efeae69d843af575fb27696f5263fe76c570a6.tar.xz
Merge branch 'jn/maint-fast-import-empty-ls' into maint
* jn/maint-fast-import-empty-ls: fast-import: don't allow 'ls' of path with empty components fast-import: leakfix for 'ls' of dirty trees
Diffstat (limited to 't/t9300-fast-import.sh')
-rwxr-xr-xt/t9300-fast-import.sh39
1 files changed, 39 insertions, 0 deletions
diff --git a/t/t9300-fast-import.sh b/t/t9300-fast-import.sh
index 438aaf6b1..0f5b5e596 100755
--- a/t/t9300-fast-import.sh
+++ b/t/t9300-fast-import.sh
@@ -1307,6 +1307,45 @@ test_expect_success \
INPUT_END'
test_expect_success \
+ 'N: reject foo/ syntax in copy source' \
+ 'test_must_fail git fast-import <<-INPUT_END
+ commit refs/heads/N5C
+ committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+ data <<COMMIT
+ copy with invalid syntax
+ COMMIT
+
+ from refs/heads/branch^0
+ C file2/ file3
+ INPUT_END'
+
+test_expect_success \
+ 'N: reject foo/ syntax in rename source' \
+ 'test_must_fail git fast-import <<-INPUT_END
+ commit refs/heads/N5D
+ committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+ data <<COMMIT
+ rename with invalid syntax
+ COMMIT
+
+ from refs/heads/branch^0
+ R file2/ file3
+ INPUT_END'
+
+test_expect_success \
+ 'N: reject foo/ syntax in ls argument' \
+ 'test_must_fail git fast-import <<-INPUT_END
+ commit refs/heads/N5E
+ committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+ data <<COMMIT
+ copy with invalid syntax
+ COMMIT
+
+ from refs/heads/branch^0
+ ls "file2/"
+ INPUT_END'
+
+test_expect_success \
'N: copy to root by id and modify' \
'echo "hello, world" >expect.foo &&
echo hello >expect.bar &&