From 03c373078830f799e8b68edcb1bac4256250d1f1 Mon Sep 17 00:00:00 2001 From: Ross McDonald Date: Wed, 2 Mar 2016 12:06:16 -0600 Subject: [PATCH] Removed test functionality from build script. closes #708 closes #713 --- CHANGELOG.md | 2 ++ scripts/build.py | 48 ++++-------------------------------------------- 2 files changed, 6 insertions(+), 44 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 79cc0a235..cf71e79aa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,8 @@ - [#781](https://github.com/influxdata/telegraf/pull/781): Fix mqtt_consumer username not being set. Thanks @chaton78! - [#786](https://github.com/influxdata/telegraf/pull/786): Fix mqtt output username not being set. Thanks @msangoi! - [#773](https://github.com/influxdata/telegraf/issues/773): Fix duplicate measurements in snmp plugin. Thanks @titilambert! +- [#708](https://github.com/influxdata/telegraf/issues/708): packaging: build ARM package +- [#713](https://github.com/influxdata/telegraf/issues/713): packaging: insecure permissions error on log directory ## v0.10.4.1 diff --git a/scripts/build.py b/scripts/build.py index 983cfae1b..950fa40e9 100755 --- a/scripts/build.py +++ b/scripts/build.py @@ -142,6 +142,10 @@ def go_get(branch, update=False, no_stash=False): run("{}/bin/gdm restore".format(os.environ.get("GOPATH"))) return True +def run_tests(race, parallel, timeout, no_vet): + # Currently a NOOP for Telegraf + return True + ################ #### All Telegraf-specific content above this line ################ @@ -324,50 +328,6 @@ def upload_packages(packages, bucket_name=None, nightly=False): print("") return 0 -def run_tests(race, parallel, timeout, no_vet): - print("Downloading vet tool...") - sys.stdout.flush() - run("go get golang.org/x/tools/cmd/vet") - print("Running tests:") - print("\tRace: {}".format(race)) - if parallel is not None: - print("\tParallel: {}".format(parallel)) - if timeout is not None: - print("\tTimeout: {}".format(timeout)) - sys.stdout.flush() - p = subprocess.Popen(["go", "fmt", "./..."], stdout=subprocess.PIPE, stderr=subprocess.PIPE) - out, err = p.communicate() - if len(out) > 0 or len(err) > 0: - print("Code not formatted. Please use 'go fmt ./...' to fix formatting errors.") - print(out) - print(err) - return False - if not no_vet: - p = subprocess.Popen(go_vet_command, stdout=subprocess.PIPE, stderr=subprocess.PIPE) - out, err = p.communicate() - if len(out) > 0 or len(err) > 0: - print("Go vet failed. Please run 'go vet ./...' and fix any errors.") - print(out) - print(err) - return False - else: - print("Skipping go vet ...") - sys.stdout.flush() - test_command = "go test -v" - if race: - test_command += " -race" - if parallel is not None: - test_command += " -parallel {}".format(parallel) - if timeout is not None: - test_command += " -timeout {}".format(timeout) - test_command += " ./..." - code = os.system(test_command) - if code != 0: - print("Tests Failed") - return False - else: - print("Tests Passed") - return True def build(version=None, branch=None,