1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-12 10:04:14 +02:00

Don't require sudo to run tests with --vm=none.

Run these tests without sudo privileges on Travis to prevent regressions.
This commit is contained in:
David Steele 2019-10-10 11:21:09 -04:00
parent 50d1d0a4e8
commit 696e6a7c44
2 changed files with 5 additions and 1 deletions

View File

@ -731,7 +731,7 @@ eval
}
executeTest(
"sudo rm -rf ${strTestPath}/test-* ${strTestPath}/data-*" .
($strVm ne VM_NONE ? 'sudo ' : '') . "rm -rf ${strTestPath}/test-* ${strTestPath}/data-*" .
($bDev ? '' : " ${strTestPath}/gcov-*"));
$oStorageTest->pathCreate($strTestPath, {strMode => '0770', bIgnoreExists => true, bCreateParent => true});

View File

@ -182,6 +182,10 @@ eval
processExec('sudo mkdir -p /tmp/pgbackrest && sudo chown root:root /tmp/pgbackrest && sudo chmod 700 /tmp/pgbackrest');
processEnd();
processBegin('remove sudo');
processExec('sudo rm /etc/sudoers.d/travis');
processEnd();
$strVmHost = VM_U18;
}
# Else run tests that require a container