mirror of
https://github.com/protocolbuffers/protobuf-go.git
synced 2024-12-29 12:17:48 +00:00
d56458e71b
Running "go build ./..." does not descend into testdata directories. However, the testdata in this repository is source code that is intended to build properly. We could rename the directory, but that does not test whether the generated packages can initialize properly. Thus, we generate a trivial test that simply blank imports all packages. Doing this reveals that some of the generated files have incorrect imports, leading to registration conflicts. To avoid introducing a dependency on gRPC from our go.mod file, we put the testdata directories in their own module. Also, we avoid running internal/testprotos through the grpc plugin because the servie and method definitions in that directory are more for testing proto file initialization rather than testing grpc generation. Change-Id: Iaa6a06449787a085200e31bc7606e3ac904d3180 Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/164917 Reviewed-by: Damien Neil <dneil@google.com>
9 lines
285 B
Bash
Executable File
9 lines
285 B
Bash
Executable File
#!/bin/bash
|
|
# Copyright 2018 The Go Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style
|
|
# license that can be found in the LICENSE file.
|
|
|
|
cd "$(git rev-parse --show-toplevel)"
|
|
go test -v -mod=vendor -timeout=60m -count=1 integration_test.go "$@"
|
|
exit $?
|