Drive kustomize repo verification from make.

This commit is contained in:
Jeffrey Regan
2019-11-14 11:00:00 -08:00
parent 875385609e
commit 003b3eccc2
5 changed files with 79 additions and 148 deletions

View File

@@ -0,0 +1,34 @@
#!/usr/bin/env bash
#
# Copyright 2019 The Kubernetes Authors.
# SPDX-License-Identifier: Apache-2.0
set -o nounset
set -o errexit
set -o pipefail
version=$1
function onLinuxAndNotOnTravis {
[[ ("linux" == "$(go env GOOS)") && (-z ${TRAVIS+x}) ]] && return
false
}
# TODO: change the label?
# We test against the latest release, and HEAD, and presumably
# any branch using this label, so it should probably get
# a new value.
mdrip --mode test \
--label testAgainstLatestRelease examples
# TODO: make work for non-linux
if onLinuxAndNotOnTravis; then
echo "On linux, and not on travis, so running the notravis example tests."
# Requires helm.
make $(go env GOPATH)/bin/helm
mdrip --mode test \
--label helmtest examples/chart.md
fi
echo "Example tests passed against ${version}."