Files
odo/scripts/openshiftci-presubmit-all-tests.sh
Anand Kumar Singh 39b8c7e4c2 fix flake and use operatorhub to install EDB (#6004)
* fix flake

Signed-off-by: anandrkskd <anandrkskd@gmail.com>

* fix flake

Signed-off-by: anandrkskd <anandrkskd@gmail.com>

* check if namespace is created

Signed-off-by: anandrkskd <anandrkskd@gmail.com>

* check if namespace without sercice is created

Signed-off-by: anandrkskd <anandrkskd@gmail.com>

Signed-off-by: anandrkskd <anandrkskd@gmail.com>
2022-08-29 11:26:57 -04:00

59 lines
1.2 KiB
Bash
Executable File

#!/bin/sh
# fail if some commands fails
set -e
# show commands
set -x
ARCH=$(uname -m)
export CI="openshift"
if [ "${ARCH}" == "s390x" ]; then
make configure-installer-tests-cluster-s390x
elif [ "${ARCH}" == "ppc64le" ]; then
make configure-installer-tests-cluster-ppc64le
else
make configure-installer-tests-cluster
fi
make bin
mkdir -p $GOPATH/bin
export PATH="$PATH:$(pwd):$GOPATH/bin"
export CUSTOM_HOMEDIR=$ARTIFACT_DIR
# Copy kubeconfig to temporary kubeconfig file
# Read and Write permission to temporary kubeconfig file
TMP_DIR=$(mktemp -d)
cp $KUBECONFIG $TMP_DIR/kubeconfig
chmod 640 $TMP_DIR/kubeconfig
export KUBECONFIG=$TMP_DIR/kubeconfig
# Login as developer
oc login -u developer -p password@123
# Check login user name for debugging purpose
oc whoami
if [ "${ARCH}" == "s390x" ]; then
# Integration tests
make test-integration
# E2e tests
make test-e2e
elif [ "${ARCH}" == "ppc64le" ]; then
# Integration tests
make test-integration
# E2e tests
make test-e2e
else
# Integration tests
make test-integration || error=true
# E2e tests
make test-e2e || error=true
# Fail the build if there is any error while test execution
if [ $error ]; then
exit -1
fi
fi
oc logout