mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
fn: api-tests are decommissioned: cleanup Makefile (#1082)
* fn: api-tests are decommissioned: cleanup Makefile * fn: increase mem in system-tests due to fn-test-utils image
This commit is contained in:
9
Makefile
9
Makefile
@@ -1,5 +1,5 @@
|
|||||||
# Just builds
|
# Just builds
|
||||||
.PHONY: all test dep build test-log-datastore checkfmt pull-images api-test fn-test-utils test-middleware test-extensions test-basic test-api
|
.PHONY: all test dep build test-log-datastore checkfmt pull-images fn-test-utils test-middleware test-extensions test-basic
|
||||||
|
|
||||||
dep:
|
dep:
|
||||||
dep ensure --vendor-only
|
dep ensure --vendor-only
|
||||||
@@ -43,12 +43,7 @@ test-extensions: test-basic
|
|||||||
test-basic: checkfmt pull-images fn-test-utils
|
test-basic: checkfmt pull-images fn-test-utils
|
||||||
./test.sh
|
./test.sh
|
||||||
|
|
||||||
test: checkfmt pull-images test-basic test-middleware test-extensions test-api test-system
|
test: checkfmt pull-images test-basic test-middleware test-extensions test-system
|
||||||
|
|
||||||
test-api: test-basic
|
|
||||||
./api_test.sh sqlite3
|
|
||||||
./api_test.sh mysql
|
|
||||||
./api_test.sh postgres
|
|
||||||
|
|
||||||
test-system: test-basic
|
test-system: test-basic
|
||||||
./system_test.sh sqlite3
|
./system_test.sh sqlite3
|
||||||
|
|||||||
33
api_test.sh
33
api_test.sh
@@ -1,33 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
set -exo pipefail
|
|
||||||
|
|
||||||
export CONTEXT="fn_api_tests"
|
|
||||||
source ./helpers.sh
|
|
||||||
remove_containers ${CONTEXT}
|
|
||||||
|
|
||||||
DB_NAME=$1
|
|
||||||
export FN_DB_URL=$(spawn_${DB_NAME} ${CONTEXT})
|
|
||||||
|
|
||||||
#test test/fn-api-tests/fn-api-tests.test
|
|
||||||
#status=`echo $?`
|
|
||||||
#rebuild="${3:-1}"
|
|
||||||
#circleci=`echo ${CIRCLECI}`
|
|
||||||
#cd test/fn-api-tests
|
|
||||||
#if [[ $status -ne 0 ]] || [[ $rebuild -ne 0 ]] ; then
|
|
||||||
# if [[ $circleci == "true" ]]; then
|
|
||||||
# # dirty things to make CI pass
|
|
||||||
# ls -lah /usr/local/go/pkg/linux_amd64/runtime
|
|
||||||
# sudo chown -R `whoami`:root /usr/local/go
|
|
||||||
# sudo chmod -R 777 /usr/local/go/pkg/linux_amd64
|
|
||||||
# ls -lah /usr/local/go/pkg/linux_amd64/runtime
|
|
||||||
# fi
|
|
||||||
# pwd
|
|
||||||
# go test -i -a -o fn-api-tests.test
|
|
||||||
#fi
|
|
||||||
#pwd
|
|
||||||
#./fn-api-tests.test -test.v -test.parallel ${2:-1} ./...; cd ../../
|
|
||||||
|
|
||||||
export FN_DS_DB_PING_MAX_RETRIES=60
|
|
||||||
cd test/fn-api-tests && FN_API_URL="http://localhost:8080" FN_DB_URL=${FN_DB_URL} go test -v ./...; cd ../../
|
|
||||||
|
|
||||||
remove_containers ${CONTEXT}
|
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -exo pipefail
|
set -exuo pipefail
|
||||||
|
|
||||||
export CONTEXT="fn_system_tests"
|
export CONTEXT="fn_system_tests"
|
||||||
source ./helpers.sh
|
source ./helpers.sh
|
||||||
@@ -22,6 +22,8 @@ export FN_ENABLE_NB_RESOURCE_TRACKER=1
|
|||||||
#
|
#
|
||||||
export SYSTEM_TEST_PROMETHEUS_FILE=./prometheus.${DB_NAME}.txt
|
export SYSTEM_TEST_PROMETHEUS_FILE=./prometheus.${DB_NAME}.txt
|
||||||
|
|
||||||
cd test/fn-system-tests && FN_DB_URL=${FN_DB_URL} FN_API_URL=${FN_API_URL} go test -v ./...; cd ../../
|
cd test/fn-system-tests
|
||||||
|
go test -v ./...
|
||||||
|
cd ../../
|
||||||
|
|
||||||
remove_containers ${CONTEXT}
|
remove_containers ${CONTEXT}
|
||||||
|
|||||||
@@ -349,7 +349,7 @@ const (
|
|||||||
routeName = "/systemtestroute"
|
routeName = "/systemtestroute"
|
||||||
image = "fnproject/fn-test-utils"
|
image = "fnproject/fn-test-utils"
|
||||||
format = "json"
|
format = "json"
|
||||||
memory = 64
|
memory = 128
|
||||||
typ = "sync"
|
typ = "sync"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user