X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft9802-git-p4-filetype.sh;h=992bb8cf0ba40104e4c6c43babcd2edbb4ac90f1;hb=3bb8d69cddbcad4bd4ae3d1281c42c1aeb297355;hp=3b358ef8d8fa485d9d43fe680b13f3961c5c79f8;hpb=9ee3d3774316f6a60c0618aa7a64fc7a59a8f338;p=git.git diff --git a/t/t9802-git-p4-filetype.sh b/t/t9802-git-p4-filetype.sh index 3b358ef8d..992bb8cf0 100755 --- a/t/t9802-git-p4-filetype.sh +++ b/t/t9802-git-p4-filetype.sh @@ -101,6 +101,37 @@ test_expect_success 'keyword file test' ' ) ' +build_gendouble() { + cat >gendouble.py <<-\EOF + import sys + import struct + import array + + s = array.array("c", '\0' * 26) + struct.pack_into(">L", s, 0, 0x00051607) # AppleDouble + struct.pack_into(">L", s, 4, 0x00020000) # version 2 + s.tofile(sys.stdout) + EOF +} + +test_expect_success 'ignore apple' ' + test_when_finished rm -f gendouble.py && + build_gendouble && + ( + cd "$cli" && + test-genrandom apple 1024 >double.png && + "$PYTHON_PATH" "$TRASH_DIRECTORY/gendouble.py" >%double.png && + p4 add -t apple double.png && + p4 submit -d appledouble + ) && + test_when_finished cleanup_git && + "$GITP4" clone --dest="$git" //depot@all && + ( + cd "$git" && + test ! -f double.png + ) +' + test_expect_success 'kill p4d' ' kill_p4d '