aboutsummaryrefslogtreecommitdiff
path: root/UnitTesting
diff options
context:
space:
mode:
authorGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2013-08-30 16:00:18 +0000
committerGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2013-08-30 16:00:18 +0000
commitb5c8dcec52097c97ca139f036c7b9cf89ff2c393 (patch)
tree5a5c9aa29fddb79bf4d2740b4a42347eb7c0f836 /UnitTesting
parent3fab2185e91f54c63c1fc534db9afb0449b70f2f (diff)
Pass optional home directory and environment variables to the iossim binary.
DELTA=11 (11 added, 0 deleted, 0 changed)
Diffstat (limited to 'UnitTesting')
-rwxr-xr-xUnitTesting/RuniOSUnitTestsUnderSimulator.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/UnitTesting/RuniOSUnitTestsUnderSimulator.sh b/UnitTesting/RuniOSUnitTestsUnderSimulator.sh
index 9bda002..4c08c99 100755
--- a/UnitTesting/RuniOSUnitTestsUnderSimulator.sh
+++ b/UnitTesting/RuniOSUnitTestsUnderSimulator.sh
@@ -176,6 +176,17 @@ GTM_TEST_COMMAND=(
if [[ "${GTM_SIMULATOR_SDK_VERSION}" != "default" ]] ; then
GTM_TEST_COMMAND+=( "-s" "${GTM_SIMULATOR_SDK_VERSION}" )
fi
+if [[ "${GTM_SIMULATOR_USER_HOME}" ]]; then
+ GTM_TEST_COMMAND+=( "-u" "${GTM_SIMULATOR_USER_HOME}" )
+fi
+# pass in extra env variables in format of "KEY1=value1 KEY2=value2"
+if [[ "${GTM_SIMULATOR_EXTRA_ENV}" ]]; then
+ EXTRA_ENV_ARRAY=(${GTM_SIMULATOR_EXTRA_ENV})
+ for i in "${!EXTRA_ENV_ARRAY[@]}"
+ do
+ GTM_TEST_COMMAND+=( "-e" ${EXTRA_ENV_ARRAY[i]} )
+ done
+fi
if [[ -n "${TEST_HOST}" ]]; then
# When using a test host, it is usually set to the executable within the app
# bundle, back up one to point at the bundle.