From 40b1d9a3199fc51d8d2e251cde814201512f26ef Mon Sep 17 00:00:00 2001 From: Shlomi Noach Date: Thu, 27 Oct 2016 20:37:03 +0200 Subject: [PATCH 1/2] gofmt testing - more verbose on intended tests --- script/cibuild | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/script/cibuild b/script/cibuild index e15c2ce..7e757b5 100755 --- a/script/cibuild +++ b/script/cibuild @@ -4,9 +4,14 @@ set -e . script/bootstrap +echo "Verifying code is formatted via 'gofmt -s -w go/'" +gofmt -s -w go/ +git diff --exit-code --quiet + +echo "Building" script/build -export GITBACKUPS_ENV=test - cd .gopath/src/github.com/github/gh-ost + +echo "Running unit tests" go test ./go/... From 5aad45e3bc8f263fc209f58a8aae104b45fc3f41 Mon Sep 17 00:00:00 2001 From: Shlomi Noach Date: Thu, 27 Oct 2016 20:38:45 +0200 Subject: [PATCH 2/2] formatted code via gofmt --- go/binlog/binlog_reader.go | 2 -- go/binlog/gomysql_reader.go | 2 -- 2 files changed, 4 deletions(-) diff --git a/go/binlog/binlog_reader.go b/go/binlog/binlog_reader.go index e7dc2cf..b4fe000 100644 --- a/go/binlog/binlog_reader.go +++ b/go/binlog/binlog_reader.go @@ -5,8 +5,6 @@ package binlog -import () - // BinlogReader is a general interface whose implementations can choose their methods of reading // a binary log file and parsing it into binlog entries type BinlogReader interface { diff --git a/go/binlog/gomysql_reader.go b/go/binlog/gomysql_reader.go index ac6d890..35f93f4 100644 --- a/go/binlog/gomysql_reader.go +++ b/go/binlog/gomysql_reader.go @@ -17,8 +17,6 @@ import ( "github.com/siddontang/go-mysql/replication" ) -var () - const ( serverId = 99999 )