Skip to content

Hotfix travis pr check #200

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Jan 25, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified Config.json.enc
Binary file not shown.
Empty file modified ThirdParty/TouchScript/Modules/TUIO/Libraries/OSCsharp.dll
100755 → 100644
Empty file.
Empty file modified ThirdParty/TouchScript/Modules/TUIO/Libraries/TUIOsharp.dll
100755 → 100644
Empty file.
66 changes: 28 additions & 38 deletions Travis/runTests.sh
Original file line number Diff line number Diff line change
@@ -1,43 +1,33 @@
#! /bin/sh
project="unity-sdk-travis"

if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then
echo '$TRAVIS_PULL_REQUEST is false, running tests'
echo "Attempting to create Streaming Assets directory..."
mkdir -p Travis/UnityTestProject/Assets/StreamingAssets/
if [ $? = 0 ] ; then
echo "Creating StreamingAssets directory COMPLETED! Exited with $?"
echo "Attempting to decrypt config..."
openssl aes-256-cbc -K $encrypted_984f19857b4c_key -iv $encrypted_984f19857b4c_iv -in Config.json.enc -out Travis/UnityTestProject/Assets/StreamingAssets/Config.json -d
if [ $? = 0 ] ; then
echo "Decrypting config COMPLETED! Exited with $?"
else
echo "Decrypting config FAILED! Exited with $?"
exit 1
fi
else
echo "Creating StreamingAssets directory FAILED! Exited with $?"
exit 1
fi
set -e

echo "Attempting to run UnitySDK integration Tests..."
/Applications/Unity/Unity.app/Contents/MacOS/Unity \
-batchmode \
-nographics \
-silent-crashes \
-logFile $(pwd)/integrationTests.log \
-projectPath $(pwd)/Travis/UnityTestProject \
-executemethod IBM.Watson.DeveloperCloud.Editor.TravisIntegrationTests.RunTests \
-quit
if [ $? = 0 ] ; then
echo "UnitTest COMPLETED! Exited with $?"
exit 0
else
echo "UnitTest FAILED! Exited with $?"
echo 'Logs tests'
cat $(pwd)/integrationTests.log
exit 1
fi
# if [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then
# echo '$TRAVIS_PULL_REQUEST is false, running tests'
echo "Attempting to create Streaming Assets directory..."
mkdir -p Travis/UnityTestProject/Assets/StreamingAssets/

echo "Attempting to decrypt config..."
openssl aes-256-cbc -K $encrypted_984f19857b4c_key -iv $encrypted_984f19857b4c_iv -in Config.json.enc -out Travis/UnityTestProject/Assets/StreamingAssets/Config.json -d

echo "Attempting to run UnitySDK integration Tests..."
/Applications/Unity/Unity.app/Contents/MacOS/Unity \
-batchmode \
-nographics \
-silent-crashes \
-logFile $(pwd)/integrationTests.log \
-projectPath $(pwd)/Travis/UnityTestProject \
-executemethod IBM.Watson.DeveloperCloud.Editor.TravisIntegrationTests.RunTests \
-quit
if [ $? = 0 ] ; then
echo "UnitTest COMPLETED! Exited with $?"
exit 0
else
echo '$TRAVIS_PULL_REQUEST is not false ($TRAVIS_PULL_REQUEST), skipping tests'
echo "UnitTest FAILED! Exited with $?"
echo 'Logs tests'
cat $(pwd)/integrationTests.log
exit 1
fi
# else
# echo '$TRAVIS_PULL_REQUEST is not false ($TRAVIS_PULL_REQUEST), skipping tests'
# fi