diff --git a/conformance/Makefile.am b/conformance/Makefile.am index 97251715..c74eb1c8 100644 --- a/conformance/Makefile.am +++ b/conformance/Makefile.am @@ -40,7 +40,7 @@ $(protoc_outputs): protoc_middleman BUILT_SOURCES = $(protoc_outputs) -CLEANFILES = $(protoc_outputs) protoc_middleman javac_middleman conformance-java +CLEANFILES = $(protoc_outputs) protoc_middleman javac_middleman conformance-java conformance-csharp MAINTAINERCLEANFILES = \ Makefile.in @@ -55,6 +55,15 @@ conformance-java: javac_middleman @echo 'java -classpath .:../java/target/classes ConformanceJava "$$@"' >> conformance-java @chmod +x conformance-java +# Currently the conformance code is alongside the rest of the C# +# source, as it's easier to maintain there. We assume we've already +# built that, so we just need a script to run it. +conformance-csharp: + @echo "Writing shortcut script conformance-csharp..." + @echo '#! /bin/sh' > conformance-csharp + @echo 'mono ../csharp/src/Google.Protobuf.Conformance/bin/Release/Google.Protobuf.Conformance.exe "$$@"' >> conformance-csharp + @chmod +x conformance-csharp + # Targets for actually running tests. test_cpp: protoc_middleman conformance-test-runner conformance-cpp ./conformance-test-runner --failure_list failure_list_cpp.txt ./conformance-cpp @@ -62,5 +71,8 @@ test_cpp: protoc_middleman conformance-test-runner conformance-cpp test_java: protoc_middleman conformance-test-runner conformance-java ./conformance-test-runner ./conformance-java +test_csharp: protoc_middleman conformance-test-runner conformance-csharp + ./conformance-test-runner --failure_list failure_list_csharp.txt ./conformance-csharp + test_ruby: protoc_middleman conformance-test-runner RUBYLIB=../ruby/lib:. ./conformance-test-runner --failure_list failure_list_ruby.txt ./conformance_ruby.rb diff --git a/conformance/failure_list_csharp.txt b/conformance/failure_list_csharp.txt new file mode 100644 index 00000000..34846589 --- /dev/null +++ b/conformance/failure_list_csharp.txt @@ -0,0 +1,22 @@ +ProtobufInput.PrematureEofBeforeUnknownValue.BOOL +ProtobufInput.PrematureEofBeforeUnknownValue.BYTES +ProtobufInput.PrematureEofBeforeUnknownValue.DOUBLE +ProtobufInput.PrematureEofBeforeUnknownValue.ENUM +ProtobufInput.PrematureEofBeforeUnknownValue.FIXED32 +ProtobufInput.PrematureEofBeforeUnknownValue.FIXED64 +ProtobufInput.PrematureEofBeforeUnknownValue.FLOAT +ProtobufInput.PrematureEofBeforeUnknownValue.INT32 +ProtobufInput.PrematureEofBeforeUnknownValue.INT64 +ProtobufInput.PrematureEofBeforeUnknownValue.MESSAGE +ProtobufInput.PrematureEofBeforeUnknownValue.SFIXED32 +ProtobufInput.PrematureEofBeforeUnknownValue.SFIXED64 +ProtobufInput.PrematureEofBeforeUnknownValue.SINT32 +ProtobufInput.PrematureEofBeforeUnknownValue.SINT64 +ProtobufInput.PrematureEofBeforeUnknownValue.STRING +ProtobufInput.PrematureEofBeforeUnknownValue.UINT32 +ProtobufInput.PrematureEofBeforeUnknownValue.UINT64 +ProtobufInput.PrematureEofInDelimitedDataForKnownNonRepeatedValue.MESSAGE +ProtobufInput.PrematureEofInDelimitedDataForKnownRepeatedValue.MESSAGE +ProtobufInput.PrematureEofInDelimitedDataForUnknownValue.BYTES +ProtobufInput.PrematureEofInDelimitedDataForUnknownValue.MESSAGE +ProtobufInput.PrematureEofInDelimitedDataForUnknownValue.STRING diff --git a/travis.sh b/travis.sh index 9514ec2b..07004571 100755 --- a/travis.sh +++ b/travis.sh @@ -29,6 +29,11 @@ build_cpp_distcheck() { } build_csharp() { + # Just for the conformance tests. We don't currently + # need to really build protoc, but it's simplest to keep with the + # conventions of the other builds. + internal_build_cpp + # Install latest version of Mono sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF echo "deb http://download.mono-project.com/repo/debian wheezy main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list @@ -39,6 +44,7 @@ build_csharp() { (cd csharp/src; mono ../../nuget.exe restore) csharp/buildall.sh + cd conformance && make test_csharp && cd .. } use_java() {