make e2e easier to read
This commit is contained in:
parent
bde21410c6
commit
bc0980b906
32
test_e2e.sh
32
test_e2e.sh
|
|
@ -119,7 +119,9 @@ touch "$REPO"/file
|
||||||
git -C "$REPO" add file
|
git -C "$REPO" add file
|
||||||
git -C "$REPO" commit -aqm "init file"
|
git -C "$REPO" commit -aqm "init file"
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test HEAD one-time
|
# Test HEAD one-time
|
||||||
|
##############################################
|
||||||
testcase "head-once"
|
testcase "head-once"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE" > "$REPO"/file
|
echo "$TESTCASE" > "$REPO"/file
|
||||||
|
|
@ -141,7 +143,9 @@ assert_file_eq "$ROOT"/link/file "$TESTCASE"
|
||||||
# Wrap up
|
# Wrap up
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test default syncing
|
# Test default syncing
|
||||||
|
##############################################
|
||||||
testcase "default-sync"
|
testcase "default-sync"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -176,7 +180,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test HEAD syncing
|
# Test HEAD syncing
|
||||||
|
##############################################
|
||||||
testcase "head-sync"
|
testcase "head-sync"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -213,7 +219,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test branch syncing
|
# Test branch syncing
|
||||||
|
##############################################
|
||||||
testcase "branch-sync"
|
testcase "branch-sync"
|
||||||
BRANCH="$TESTCASE"--BRANCH
|
BRANCH="$TESTCASE"--BRANCH
|
||||||
# First sync
|
# First sync
|
||||||
|
|
@ -256,7 +264,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test tag syncing
|
# Test tag syncing
|
||||||
|
##############################################
|
||||||
testcase "tag-sync"
|
testcase "tag-sync"
|
||||||
TAG="$TESTCASE"--TAG
|
TAG="$TESTCASE"--TAG
|
||||||
# First sync
|
# First sync
|
||||||
|
|
@ -303,7 +313,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test tag syncing with annotated tags
|
# Test tag syncing with annotated tags
|
||||||
|
##############################################
|
||||||
testcase "tag-sync-annotated"
|
testcase "tag-sync-annotated"
|
||||||
TAG="$TESTCASE"--TAG
|
TAG="$TESTCASE"--TAG
|
||||||
# First sync
|
# First sync
|
||||||
|
|
@ -350,7 +362,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test cross-branch tag syncing
|
# Test cross-branch tag syncing
|
||||||
|
##############################################
|
||||||
testcase "cross-branch-tag-sync"
|
testcase "cross-branch-tag-sync"
|
||||||
BRANCH="$TESTCASE"--BRANCH
|
BRANCH="$TESTCASE"--BRANCH
|
||||||
TAG="$TESTCASE"--TAG
|
TAG="$TESTCASE"--TAG
|
||||||
|
|
@ -414,7 +428,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test rev syncing
|
# Test rev syncing
|
||||||
|
##############################################
|
||||||
testcase "rev-sync"
|
testcase "rev-sync"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -451,7 +467,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test rev-sync one-time
|
# Test rev-sync one-time
|
||||||
|
##############################################
|
||||||
testcase "rev-once"
|
testcase "rev-once"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE" > "$REPO"/file
|
echo "$TESTCASE" > "$REPO"/file
|
||||||
|
|
@ -474,7 +492,9 @@ assert_file_eq "$ROOT"/link/file "$TESTCASE"
|
||||||
# Wrap up
|
# Wrap up
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test syncing after a crash
|
# Test syncing after a crash
|
||||||
|
##############################################
|
||||||
testcase "crash-cleanup-retry"
|
testcase "crash-cleanup-retry"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -509,7 +529,9 @@ assert_file_eq "$ROOT"/link/file "$TESTCASE 1"
|
||||||
# Wrap up
|
# Wrap up
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test sync loop timeout
|
# Test sync loop timeout
|
||||||
|
##############################################
|
||||||
testcase "sync-loop-timeout"
|
testcase "sync-loop-timeout"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -554,7 +576,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test depth syncing
|
# Test depth syncing
|
||||||
|
##############################################
|
||||||
testcase "depth"
|
testcase "depth"
|
||||||
# First sync
|
# First sync
|
||||||
echo "$TESTCASE 1" > "$REPO"/file
|
echo "$TESTCASE 1" > "$REPO"/file
|
||||||
|
|
@ -603,7 +627,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test webhook
|
# Test webhook
|
||||||
|
##############################################
|
||||||
testcase "webhook"
|
testcase "webhook"
|
||||||
NCPORT=8888
|
NCPORT=8888
|
||||||
# First sync
|
# First sync
|
||||||
|
|
@ -646,7 +672,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test http handler
|
# Test http handler
|
||||||
|
##############################################
|
||||||
testcase "http"
|
testcase "http"
|
||||||
BINDPORT=8888
|
BINDPORT=8888
|
||||||
# First sync
|
# First sync
|
||||||
|
|
@ -680,7 +708,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test submodule sync
|
# Test submodule sync
|
||||||
|
##############################################
|
||||||
testcase "submodule-sync"
|
testcase "submodule-sync"
|
||||||
|
|
||||||
# Init submodule repo
|
# Init submodule repo
|
||||||
|
|
@ -779,7 +809,9 @@ remove_sync_container
|
||||||
wait
|
wait
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
##############################################
|
||||||
# Test submodules depth syncing
|
# Test submodules depth syncing
|
||||||
|
##############################################
|
||||||
testcase "submodule-sync-depth"
|
testcase "submodule-sync-depth"
|
||||||
|
|
||||||
# Init submodule repo
|
# Init submodule repo
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue