代码拉取完成,页面将自动刷新
#!/bin/bash
quit_on_error() {
echo "Error on line $1, stopping build."
exit 1
}
list_dir() {
echo "listing directory $1 :"
ls -al $1
}
trap 'quit_on_error $LINENO' ERR
CATEGORY=$1
TRAVIS_BUILD_DIR=${2:-.}
if id travis &> /dev/null
then
TESTUSER=travis
else
TESTUSER=$(whoami)
fi
echo "Build script starting with parameters TRAVIS_BUILD_DIR=$TRAVIS_BUILD_DIR and CATEGORY=$CATEGORY"
# build duplicati
list_dir "${TRAVIS_BUILD_DIR}"/packages/
echo "travis_fold:start:build_duplicati"
msbuild /p:Configuration=Release Duplicati.sln
cp -r ./Duplicati/Server/webroot ./Duplicati/GUI/Duplicati.GUI.TrayIcon/bin/Release/webroot
echo "travis_fold:end:build_duplicati"
rm -rf ~/duplicati_testdata && mkdir ~/duplicati_testdata
chown -R $TESTUSER ~/duplicati_testdata/
chmod -R 755 ~/duplicati_testdata
# run unit tests
echo "travis_fold:start:unit_test"
if [[ "$CATEGORY" != "GUI" && "$CATEGORY" != "" ]]; then
mono ./testrunner/NUnit.ConsoleRunner.3.10.0/tools/nunit3-console.exe \
./Duplicati/UnitTest/bin/Release/Duplicati.UnitTest.dll --where:cat==$CATEGORY --workers=1
fi
echo "travis_fold:end:unit_test"
# start server and run gui tests
echo "travis_fold:start:gui_unit_test"
if [[ "$CATEGORY" == "GUI" ]]; then
mono ./Duplicati/GUI/Duplicati.GUI.TrayIcon/bin/Release/Duplicati.Server.exe &
python guiTests/guiTest.py
fi
echo "travis_fold:end:gui_unit_test"
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。