ADD: added new version of protobuf
This commit is contained in:
@@ -1,16 +0,0 @@
|
||||
load("//build_defs:internal_shell.bzl", "inline_sh_test")
|
||||
|
||||
# Run csharp compatibility test between 3.0.0 and the current version.
|
||||
inline_sh_test(
|
||||
name = "tests",
|
||||
srcs = ["test.sh"],
|
||||
tools = ["//:protoc"],
|
||||
deps = glob([
|
||||
"src/**/*.cs*", # .cs and .csproj
|
||||
"protos/**/*.proto",
|
||||
]) + [
|
||||
"//csharp:srcs",
|
||||
"//:well_known_protos",
|
||||
],
|
||||
cmd = "$(location test.sh) 3.0.0 $(rootpath //:protoc)"
|
||||
)
|
||||
@@ -6,7 +6,6 @@
|
||||
<AssemblyOriginatorKeyFile>../../keys/Google.Protobuf.snk</AssemblyOriginatorKeyFile>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
<IsPackable>False</IsPackable>
|
||||
<LangVersion>8.0</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -27,8 +27,6 @@ function run_test() {
|
||||
|
||||
set -ex
|
||||
|
||||
PROTOC=$(realpath ${2:-../../../bazel-bin/protoc})
|
||||
|
||||
# Change to the script's directory.
|
||||
cd $(dirname $0)
|
||||
|
||||
@@ -47,7 +45,7 @@ OLD_VERSION_PROTOC=https://repo1.maven.org/maven2/com/google/protobuf/protoc/$OL
|
||||
echo "Running compatibility tests with $OLD_VERSION"
|
||||
|
||||
# Check protoc
|
||||
[ -f $PROTOC ] || {
|
||||
[ -f ../../../src/protoc ] || {
|
||||
echo "[ERROR]: Please build protoc first."
|
||||
exit 1
|
||||
}
|
||||
@@ -70,12 +68,12 @@ run_test "./old_protoc" "./old_protoc"
|
||||
# Test A.2:
|
||||
# proto set 1: use new version
|
||||
# proto set 2 which may import protos in set 1: use old version
|
||||
run_test "$PROTOC" "./old_protoc"
|
||||
run_test "../../../src/protoc" "./old_protoc"
|
||||
|
||||
# Test A.3:
|
||||
# proto set 1: use old version
|
||||
# proto set 2 which may import protos in set 1: use new version
|
||||
run_test "./old_protoc" "$PROTOC"
|
||||
run_test "./old_protoc" "../../../src/protoc"
|
||||
|
||||
rm old_protoc
|
||||
rm keys -r
|
||||
|
||||
Reference in New Issue
Block a user