Merge ~rmescandon/snappy-hwe-snaps/+git/wifi-connect:golang-skip-tests-support into ~snappy-hwe-team/snappy-hwe-snaps/+git/wifi-connect:master

Proposed by Roberto Mier Escandon
Status: Merged
Approved by: Kyle Nitzsche
Approved revision: 4de21abd7b23862ac038aacb1a17db71ead98230
Merged at revision: fe4fd9326f0cc32f5fb8cec2ccdcdda0ea7bb506
Proposed branch: ~rmescandon/snappy-hwe-snaps/+git/wifi-connect:golang-skip-tests-support
Merge into: ~snappy-hwe-team/snappy-hwe-snaps/+git/wifi-connect:master
Diff against target: 17 lines (+6/-0)
1 file modified
snap/snapcraft.yaml (+6/-0)
Reviewer Review Type Date Requested Status
Kyle Nitzsche (community) Approve
System Enablement Bot continuous-integration Approve
Review via email: mp+325909@code.launchpad.net

Description of the change

allow skip unit tests by setting environment var SKIP_TESTS to y or yes. We discourage using this option, but in case you need it to force a quicker snapcraft, do it only in dev environments.

To post a comment you must log in.
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Kyle Nitzsche (knitzsche) wrote :

thanks - this will allow us to speed up development.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml
2index b5f8aad..8bd7f04 100644
3--- a/snap/snapcraft.yaml
4+++ b/snap/snapcraft.yaml
5@@ -37,6 +37,12 @@ parts:
6 # needed by go get
7 - bzr
8 install: |
9+ # set environment var SKIP_TESTS to 'y' or 'yes' if you want not to execute
10+ # this part unit tests in your next compilation.
11+ if [ "$SKIP_TESTS" = "yes" ] || [ "$SKIP_TESTS" = "y" ]; then
12+ echo "skipping unit tests"
13+ exit 0
14+ fi
15 export GOPATH=$PWD/../go
16 cd $GOPATH/src/launchpad.net/wifi-connect
17 ./run-checks all

Subscribers

People subscribed via source and target branches