Capture timestamp whenever cleanup is triggered in tests (#2054)
Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
@@ -16,6 +16,7 @@ url=""
|
||||
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ mkdir -p $tmp_dir
|
||||
ROOT=$(dirname $0)/../../..
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ fn_p=pbuilderhello-$TEST_ID
|
||||
fn_n=nbuilderhello-$TEST_ID
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@ fn_n=jvm-hello-n-$TEST_ID
|
||||
fn_p=jvm-hello-p-$TEST_ID
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
}
|
||||
|
||||
|
||||
@@ -12,6 +12,7 @@ mkdir -p $tmp_dir
|
||||
ROOT=$(dirname $0)/../../..
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ mkdir -p $tmp_dir
|
||||
ROOT=$(dirname $0)/../../..
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ mkdir -p $tmp_dir
|
||||
ROOT=$(dirname $0)/../../..
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf $tmp_dir
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ ROOT=$(dirname $0)/../../..
|
||||
pushd $ROOT/test/tests/test_huge_response
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
rm -rf response.json
|
||||
popd
|
||||
|
||||
@@ -17,6 +17,7 @@ hostName="test-$TEST_ID.com"
|
||||
routeName="ingress-$TEST_ID"
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
clean_resource_by_id $TEST_ID
|
||||
}
|
||||
|
||||
|
||||
@@ -36,8 +36,6 @@ fi
|
||||
log "Creating nodejs env"
|
||||
fission env create --name $env --image $NODE_RUNTIME_IMAGE
|
||||
|
||||
|
||||
|
||||
for f in $f1 $f2
|
||||
do
|
||||
echo "module.exports = function(context, callback) { callback(200, \"$f\n\"); }" > $tmp_dir/$f.js
|
||||
|
||||
@@ -14,6 +14,7 @@ ROOT=$(dirname $0)/../../..
|
||||
cd $ROOT/test/tests/test_kubectl
|
||||
|
||||
cleanup() {
|
||||
log "Cleaning up..."
|
||||
kubectl delete -f spec-yaml -R || true
|
||||
}
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ env_n=nodend
|
||||
fn_nd=nodehellond
|
||||
|
||||
cleanup() {
|
||||
echo "Cleaning up..."
|
||||
log "Cleaning up..."
|
||||
fission spec destroy || true
|
||||
popd
|
||||
}
|
||||
@@ -32,11 +32,11 @@ fission fn test --name $fn_nd
|
||||
hnd=$(kubectl -n $FUNCTION_NAMESPACE get deployment -l=functionName=$fn_nd -ojsonpath='{.items[0].spec.template.spec.hostname}')
|
||||
|
||||
if [[ "${hnd}" == "foo-bar" ]]; then
|
||||
echo "Hostname matches for newdeployment function, podspec test 1/2 passsed"
|
||||
log "Hostname matches for newdeployment function, podspec test 1/2 passsed"
|
||||
fi
|
||||
|
||||
hnp=$(kubectl -n $FUNCTION_NAMESPACE get deployment -l=environmentName=$env_p -ojsonpath='{.items[0].spec.template.spec.hostname}')
|
||||
|
||||
if [[ "${hnp}" == "foo-bar" ]]; then
|
||||
echo "Hostname matches for poolmgr function, podspec test 2/2 passsed"
|
||||
log "Hostname matches for poolmgr function, podspec test 2/2 passsed"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user