|
|
|
@ -306,7 +306,7 @@ function setUp () {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# This test has to be done everytime in order for osync executable to be fresh
|
|
|
|
|
function nope_test_Merge () {
|
|
|
|
|
function test_Merge () {
|
|
|
|
|
cd "$DEV_DIR"
|
|
|
|
|
./merge.sh osync
|
|
|
|
|
assertEquals "Merging code" "0" $?
|
|
|
|
@ -335,7 +335,7 @@ function nope_test_Merge () {
|
|
|
|
|
assertEquals "Install failed" "0" $?
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_LargeFileSet () {
|
|
|
|
|
function test_LargeFileSet () {
|
|
|
|
|
for i in "${osyncParameters[@]}"; do
|
|
|
|
|
cd "$OSYNC_DIR"
|
|
|
|
|
|
|
|
|
@ -353,7 +353,7 @@ function nope_test_LargeFileSet () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_controlMaster () {
|
|
|
|
|
function test_controlMaster () {
|
|
|
|
|
cd "$OSYNC_DIR"
|
|
|
|
|
|
|
|
|
|
PrepareLocalDirs
|
|
|
|
@ -362,7 +362,7 @@ function nope_test_controlMaster () {
|
|
|
|
|
assertEquals "Running quick remote test with controlmaster enabled." "0" $?
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_Exclusions () {
|
|
|
|
|
function test_Exclusions () {
|
|
|
|
|
# Will sync except php files
|
|
|
|
|
# RSYNC_EXCLUDE_PATTERN="*.php" is set at runtime for quicksync and in config files for other runs
|
|
|
|
|
|
|
|
|
@ -390,7 +390,7 @@ function nope_test_Exclusions () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_Deletetion () {
|
|
|
|
|
function test_Deletetion () {
|
|
|
|
|
local iFile1="$INITIATOR_DIR/i fic"
|
|
|
|
|
local iFile2="$INITIATOR_DIR/i foc"
|
|
|
|
|
local tFile1="$TARGET_DIR/t fic"
|
|
|
|
@ -434,7 +434,7 @@ function nope_test_Deletetion () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_deletion_failure () {
|
|
|
|
|
function test_deletion_failure () {
|
|
|
|
|
if [ "$LOCAL_OS" == "WinNT10" ] || [ "$LOCAL_OS" == "msys" ] || [ "$LOCAL_OS" == "Cygwin" ]; then
|
|
|
|
|
echo "Skipping deletion failure test as Win10 does not have chattr support."
|
|
|
|
|
return 0
|
|
|
|
@ -501,7 +501,7 @@ function nope_test_deletion_failure () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_skip_deletion () {
|
|
|
|
|
function test_skip_deletion () {
|
|
|
|
|
local modes
|
|
|
|
|
|
|
|
|
|
if [ "$OSYNC_MIN_VERSION" == "1" ]; then
|
|
|
|
@ -577,7 +577,7 @@ function nope_test_skip_deletion () {
|
|
|
|
|
SetConfFileValue "$CONF_DIR/$REMOTE_CONF" "SKIP_DELETION" ""
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_handle_symlinks () {
|
|
|
|
|
function test_handle_symlinks () {
|
|
|
|
|
if [ "$OSYNC_MIN_VERSION" == "1" ]; then
|
|
|
|
|
echo "Skipping symlink tests as osync v1.1x didn't handle this."
|
|
|
|
|
return 0
|
|
|
|
@ -758,7 +758,7 @@ function nope_test_handle_symlinks () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_softdeletion_cleanup () {
|
|
|
|
|
function test_softdeletion_cleanup () {
|
|
|
|
|
#declare -A files
|
|
|
|
|
|
|
|
|
|
files=()
|
|
|
|
@ -835,7 +835,7 @@ function nope_test_softdeletion_cleanup () {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_FileAttributePropagation () {
|
|
|
|
|
function test_FileAttributePropagation () {
|
|
|
|
|
|
|
|
|
|
if [ "$TRAVIS_RUN" == true ]; then
|
|
|
|
|
echo "Skipping FileAttributePropagation tests as travis does not support getfacl / setfacl."
|
|
|
|
@ -923,7 +923,7 @@ function nope_test_FileAttributePropagation () {
|
|
|
|
|
SetConfFileValue "$CONF_DIR/$REMOTE_CONF" "PRESERVE_XATTR" false
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_ConflictBackups () {
|
|
|
|
|
function test_ConflictBackups () {
|
|
|
|
|
for i in "${osyncParameters[@]}"; do
|
|
|
|
|
cd "$OSYNC_DIR"
|
|
|
|
|
PrepareLocalDirs
|
|
|
|
@ -959,7 +959,7 @@ function nope_test_ConflictBackups () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_MultipleConflictBackups () {
|
|
|
|
|
function test_MultipleConflictBackups () {
|
|
|
|
|
|
|
|
|
|
local additionalParameters
|
|
|
|
|
|
|
|
|
@ -1021,7 +1021,7 @@ function nope_test_MultipleConflictBackups () {
|
|
|
|
|
SetConfFileValue "$CONF_DIR/$REMOTE_CONF" "CONFLICT_BACKUP_MULTIPLE" false
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_Locking () {
|
|
|
|
|
function test_Locking () {
|
|
|
|
|
# local not running = resume
|
|
|
|
|
# remote same instance_id = resume
|
|
|
|
|
# remote different instance_id = stop
|
|
|
|
@ -1128,7 +1128,7 @@ function nope_test_Locking () {
|
|
|
|
|
SetConfFileValue "$CONF_DIR/$REMOTE_CONF" "FORCE_STRANGER_LOCK_RESUME" false
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_ConflictDetetion () {
|
|
|
|
|
function test_ConflictDetetion () {
|
|
|
|
|
# Tests compatible with v1.4+
|
|
|
|
|
|
|
|
|
|
if [ $OSYNC_MIN_VERSION -lt 4 ]; then
|
|
|
|
@ -1179,7 +1179,7 @@ function nope_test_ConflictDetetion () {
|
|
|
|
|
return 0
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_WaitForTaskCompletion () {
|
|
|
|
|
function test_WaitForTaskCompletion () {
|
|
|
|
|
local pids
|
|
|
|
|
|
|
|
|
|
# Tests compatible with v1.1 syntax
|
|
|
|
@ -1273,7 +1273,7 @@ function nope_test_WaitForTaskCompletion () {
|
|
|
|
|
assertEquals "WaitForTaskCompletion test 5" "2" $?
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_ParallelExec () {
|
|
|
|
|
function test_ParallelExec () {
|
|
|
|
|
if [ "$OSYNC_MIN_VERSION" == "1" ]; then
|
|
|
|
|
echo "Skipping ParallelExec test because osync v1.1 ofunctions don't have this function."
|
|
|
|
|
return 0
|
|
|
|
@ -1334,7 +1334,7 @@ function nope_test_ParallelExec () {
|
|
|
|
|
assertNotEquals "ParallelExec full test 3" "0" $?
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_timedExecution () {
|
|
|
|
|
function test_timedExecution () {
|
|
|
|
|
local arguments
|
|
|
|
|
|
|
|
|
|
# Clever usage of indexes and exit codes
|
|
|
|
@ -1380,7 +1380,7 @@ function nope_test_timedExecution () {
|
|
|
|
|
done
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_UpgradeConfRun () {
|
|
|
|
|
function test_UpgradeConfRun () {
|
|
|
|
|
if [ "$OSYNC_MIN_VERSION" == "1" ]; then
|
|
|
|
|
echo "Skipping Upgrade script test because no further dev will happen on this for v1.1"
|
|
|
|
|
return 0
|
|
|
|
@ -1406,7 +1406,7 @@ function nope_test_UpgradeConfRun () {
|
|
|
|
|
rm -f "$CONF_DIR/$TMP_OLD_CONF.save"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_DaemonMode () {
|
|
|
|
|
function test_DaemonMode () {
|
|
|
|
|
if [ "$LOCAL_OS" == "WinNT10" ] || [ "$LOCAL_OS" == "msys" ] || [ "$LOCAL_OS" == "Cygwin" ]; then
|
|
|
|
|
echo "Skipping daemon mode test as [$LOCAL_OS] does not have inotifywait support."
|
|
|
|
|
return 0
|
|
|
|
@ -1462,7 +1462,7 @@ function nope_test_DaemonMode () {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function nope_test_NoRemoteAccessTest () {
|
|
|
|
|
function test_NoRemoteAccessTest () {
|
|
|
|
|
RemoveSSH
|
|
|
|
|
|
|
|
|
|
cd "$OSYNC_DIR"
|
|
|
|
|