Skip to content
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

substituting the os name in the paths used in running the test #461

Open
wants to merge 1 commit into
base: snappy/master
Choose a base branch
from
Open
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
8 changes: 6 additions & 2 deletions tests/core/src/main/java/bin/run-snappy-store-bt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,11 @@ else
shift
fi
OSTYPE=`uname -a | sed -e 's/ .*//' -e 's/CYG.*/Windows_NT/' -e 's/SunOS/Solaris/'`

OS=linux
if [ ${OSTYPE} = "Darwin" ]; then
OS="osx"
fi

TESTBIN=`dirname $0`
# provieded osbuild dir
OSBUILD=${OVERRIDE_OSBUILD}
Expand All @@ -73,7 +77,7 @@ SOURCES=$TESTBIN/../../../../../..
export NO_BUILD_LOG=true
export JPROBE_HOME=/do/not/use/JPROBE
options=''
TESTSPATH=${SOURCES}/tests/sql/build-artifacts/linux/classes/java/main
TESTSPATH=${SOURCES}/tests/sql/build-artifacts/${OS}/classes/java/main
export CLASSPATH=${TESTSPATH}:$CLASSPATH
while [ $# -gt 0 ]; do

Expand Down
13 changes: 9 additions & 4 deletions tests/core/src/main/java/bin/sample-runbt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,13 @@ fi
SNAPPYDATADIR=$1
shift

export JTESTS=$SNAPPYDATADIR/store/tests/sql/build-artifacts/linux/classes/java/main
OSTYPE=`uname -a | sed -e 's/ .*//' -e 's/CYG.*/Windows_NT/' -e 's/SunOS/Solaris/'`
OS=linux
if [ ${OSTYPE} = "Darwin" ]; then
OS="osx"
fi

export JTESTS=$SNAPPYDATADIR/store/tests/sql/build-artifacts/${OS}/classes/java/main
export PATH=$JAVA_HOME:$PATH:$JTESTS
export GEMFIRE=$SNAPPYDATADIR/build-artifacts/scala-2.11/store
export OUTPUT_DIR=$resultDir
Expand Down Expand Up @@ -90,12 +96,11 @@ export snappyTestsJarVersion=`echo "${snappyTestsJarFilename%*.*}"| cut -d'-' -f
CLASSPATH=$JTESTS:$EXTRA_JTESTS:$JTESTS/../../../libs/snappydata-store-hydra-tests-${releaseVersion}-all.jar:$SNAPPYDATADIR/dtests/build-artifacts/scala-2.11/libs/snappydata-store-scala-tests-${snappyTestsJarVersion}-tests.jar
LIB=$SNAPPYDATADIR/build-artifacts/scala-2.11/snappy/jars
for i in $LIB/*.jar; do CLASSPATH=$CLASSPATH:$i; done

export CLASSPATH=$CLASSPATH
export EXTRA_JTESTS=$SNAPPYDATADIR/store/tests/core/build-artifacts/linux/classes/java/main
export EXTRA_JTESTS=$SNAPPYDATADIR/store/tests/core/build-artifacts/${OS}/classes/java/main
#export JTESTS_RESOURCES=$SNAPPYDATADIR/store/tests/core/src/main/java

# This is the command to run the test, make sure the correct release version of jar used or change the jar path to use correctly. Also change the jar name in sql/snappy.local.conf if incorrect

echo $SNAPPYDATADIR/store/tests/core/src/main/java/bin/run-snappy-store-bt.sh --osbuild $GEMFIRE $OUTPUT_DIR -Dproduct=snappystore -DtestJVM=$TEST_JVM/bin/java -DEXTRA_JTESTS=$EXTRA_JTESTS -Dbt.grepLogs=true -DremovePassedTest=$deleteTestLogs -DnumTimesToRun=$runIters -DlocalConf=$localconfpath ${bts}
$SNAPPYDATADIR/store/tests/core/src/main/java/bin/run-snappy-store-bt.sh --osbuild $GEMFIRE $OUTPUT_DIR -Dproduct=snappystore -DtestJVM=$TEST_JVM/bin/java -DEXTRA_JTESTS=$EXTRA_JTESTS -Dbt.mergeLogFiles=true -Dbt.grepLogs=true -DremovePassedTest=$deleteTestLogs -DnumTimesToRun=$runIters -DlocalConf=$localconfpath ${bts}
$SNAPPYDATADIR/store/tests/core/src/main/java/bin/run-snappy-store-bt.sh --osbuild $GEMFIRE $OUTPUT_DIR -Dproduct=snappystore -DtestJVM=$TEST_JVM/bin/java -DEXTRA_JTESTS=$EXTRA_JTESTS -Dbt.mergeLogFiles=true -Dbt.grepLogs=true -DremovePassedTest=$deleteTestLogs -DnumTimesToRun=$runIters -DlocalConf=$localconfpath ${bts}