git-svn: support for git-svn propset
[gitweb.git] / t / t9811-git-p4-label-import.sh
index 85d60494bf44609766d5a51fba03801dcbea0c21..095238fffe2757a5bf1c5c2f877791117fbf09a3 100755 (executable)
@@ -30,7 +30,7 @@ test_expect_success 'basic p4 labels' '
 
                p4 tag -l TAG_F1_ONLY main/f1 &&
                p4 tag -l TAG_WITH\$_SHELL_CHAR main/... &&
-               p4 tag -l this_tag_will_be_skipped main/... &&
+               p4 tag -l this_tag_will_beskipped main/... &&
 
                echo f4 >main/f4 &&
                p4 add main/f4 &&
@@ -50,7 +50,7 @@ test_expect_success 'basic p4 labels' '
 
                git p4 clone --dest="$git" //depot@all &&
                cd "$git" &&
-               git config git-p4.validLabelRegexp ".*TAG.*" &&
+               git config git-p4.labelImportRegexp ".*TAG.*" &&
                git p4 sync --import-labels --verbose &&
 
                git tag &&
@@ -195,6 +195,26 @@ test_expect_success 'tag that cannot be exported' '
        )
 '
 
+test_expect_success 'use git config to enable import/export of tags' '
+       git p4 clone --verbose --dest="$git" //depot@all &&
+       (
+               cd "$git" &&
+               git config git-p4.exportLabels true &&
+               git config git-p4.importLabels true &&
+               git tag CFG_A_GIT_TAG &&
+               git p4 rebase --verbose &&
+               git p4 submit --verbose &&
+               git tag &&
+               git tag | grep TAG_F1_1
+       ) &&
+       (
+               cd "$cli" &&
+               p4 labels &&
+               p4 labels | grep CFG_A_GIT_TAG
+       )
+'
+
+
 test_expect_success 'kill p4d' '
        kill_p4d
 '