Skip to content

Commit 63a0c09

Browse files
committed
Wrapped last part in IF
1 parent 2dba35f commit 63a0c09

File tree

2 files changed

+31
-40
lines changed

2 files changed

+31
-40
lines changed

.circleci/config.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ jobs:
374374
resource_class: medium
375375
parallelism: 4
376376
environment:
377-
E2E_SUBS_SCRIPTS: "SKIP"
377+
E2E_TEST_FILTER: "GO"
378378
steps:
379379
- prepare_go
380380
- generic_integration:
@@ -387,7 +387,7 @@ jobs:
387387
resource_class: medium
388388
parallelism: 4
389389
environment:
390-
E2E_SUBS_SCRIPTS: "SKIP"
390+
E2E_TEST_FILTER: "GO"
391391
steps:
392392
- prepare_go
393393
- generic_integration:
@@ -399,7 +399,7 @@ jobs:
399399
image: ubuntu-2004:202104-01
400400
resource_class: large
401401
environment:
402-
E2E_SUBS_SCRIPTS: "ONLY"
402+
E2E_TEST_FILTER: "SCRIPTS"
403403
steps:
404404
- prepare_go
405405
- generic_integration:
@@ -411,7 +411,7 @@ jobs:
411411
image: ubuntu-2004:202104-01
412412
resource_class: large
413413
environment:
414-
E2E_SUBS_SCRIPTS: "ONLY"
414+
E2E_TEST_FILTER: "SCRIPTS"
415415
steps:
416416
- prepare_go
417417
- generic_integration:
@@ -459,7 +459,7 @@ jobs:
459459
resource_class: arm.medium
460460
parallelism: 4
461461
environment:
462-
E2E_SUBS_SCRIPTS: "SKIP"
462+
E2E_TEST_FILTER: "GO"
463463
steps:
464464
- checkout
465465
- prepare_go
@@ -473,7 +473,7 @@ jobs:
473473
resource_class: arm.medium
474474
parallelism: 4
475475
environment:
476-
E2E_SUBS_SCRIPTS: "SKIP"
476+
E2E_TEST_FILTER: "GO"
477477
steps:
478478
- checkout
479479
- prepare_go
@@ -486,7 +486,7 @@ jobs:
486486
image: ubuntu-2004:202101-01
487487
resource_class: arm.large
488488
environment:
489-
E2E_SUBS_SCRIPTS: "ONLY"
489+
E2E_TEST_FILTER: "SCRIPTS"
490490
steps:
491491
- checkout
492492
- prepare_go
@@ -499,7 +499,7 @@ jobs:
499499
image: ubuntu-2004:202101-01
500500
resource_class: arm.large
501501
environment:
502-
E2E_SUBS_SCRIPTS: "ONLY"
502+
E2E_TEST_FILTER: "SCRIPTS"
503503
steps:
504504
- checkout
505505
- prepare_go
@@ -558,7 +558,7 @@ jobs:
558558
resource_class: medium
559559
parallelism: 4
560560
environment:
561-
E2E_SUBS_SCRIPTS: "SKIP"
561+
E2E_TEST_FILTER: "GO"
562562
HOMEBREW_NO_AUTO_UPDATE: "true"
563563
steps:
564564
#- run: git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow
@@ -574,7 +574,7 @@ jobs:
574574
resource_class: medium
575575
parallelism: 4
576576
environment:
577-
E2E_SUBS_SCRIPTS: "SKIP"
577+
E2E_TEST_FILTER: "GO"
578578
HOMEBREW_NO_AUTO_UPDATE: "true"
579579
steps:
580580
#- run: git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow
@@ -589,7 +589,7 @@ jobs:
589589
xcode: 12.0.1
590590
resource_class: large
591591
environment:
592-
E2E_SUBS_SCRIPTS: "ONLY"
592+
E2E_TEST_FILTER: "SCRIPTS"
593593
HOMEBREW_NO_AUTO_UPDATE: "true"
594594
steps:
595595
#- run: git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow
@@ -604,7 +604,7 @@ jobs:
604604
xcode: 12.0.1
605605
resource_class: large
606606
environment:
607-
E2E_SUBS_SCRIPTS: "ONLY"
607+
E2E_TEST_FILTER: "SCRIPTS"
608608
HOMEBREW_NO_AUTO_UPDATE: "true"
609609
steps:
610610
#- run: git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow

test/scripts/e2e.sh

Lines changed: 19 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ export GOPATH=$(go env GOPATH)
100100
# Change current directory to test/scripts so we can just use ./test.sh to exec.
101101
cd "${SCRIPT_PATH}"
102102

103-
e2e_subs_scripts()
104-
{
103+
if [ -z $E2E_TEST_FILTER || $E2E_TEST_FILTER="SCRIPTS" ]; then
104+
105105
./timeout 200 ./e2e_basic_start_stop.sh
106106
duration "e2e_basic_start_stop.sh"
107107

@@ -125,34 +125,25 @@ e2e_subs_scripts()
125125
duration "serial client runners"
126126

127127
deactivate
128-
}
129-
130-
case $E2E_SUBS_SCRIPTS in
131-
SKIP)
132-
;;
133-
ONLY)
134-
exit 0
135-
;;
136-
*)
137-
e2e_subs_scripts
138-
;;
139-
esac
128+
fi # if E2E_TEST_FILTER = "" or = "SCRIPTS"
140129

141-
# Export our root temp folder as 'TESTDIR' for tests to use as their root test folder
142-
# This allows us to clean up everything with our rm -rf trap.
143-
export TESTDIR=${TEMPDIR}
144-
export TESTDATADIR=${SRCROOT}/test/testdata
145-
export SRCROOT=${SRCROOT}
130+
if [ -z $E2E_TEST_FILTER || $E2E_TEST_FILTER="GO" ]; then
131+
# Export our root temp folder as 'TESTDIR' for tests to use as their root test folder
132+
# This allows us to clean up everything with our rm -rf trap.
133+
export TESTDIR=${TEMPDIR}
134+
export TESTDATADIR=${SRCROOT}/test/testdata
135+
export SRCROOT=${SRCROOT}
146136

147-
./e2e_go_tests.sh ${GO_TEST_ARGS}
148-
duration "e2e_go_tests.sh"
137+
./e2e_go_tests.sh ${GO_TEST_ARGS}
138+
duration "e2e_go_tests.sh"
149139

150-
rm -rf "${TEMPDIR}"
140+
rm -rf "${TEMPDIR}"
151141

152-
if ! ${NO_BUILD} ; then
153-
rm -rf ${PKG_ROOT}
154-
fi
142+
if ! ${NO_BUILD} ; then
143+
rm -rf ${PKG_ROOT}
144+
fi
155145

156-
echo "----------------------------------------------------------------------"
157-
echo " DONE: E2E"
158-
echo "----------------------------------------------------------------------"
146+
echo "----------------------------------------------------------------------"
147+
echo " DONE: E2E"
148+
echo "----------------------------------------------------------------------"
149+
fi # if E2E_TEST_FILTER = "" or = "GO"

0 commit comments

Comments
 (0)