From 23a90b7dccf4aef4c083fb37d6a8ea26c3cae783 Mon Sep 17 00:00:00 2001 From: wing328 Date: Sat, 13 Feb 2016 17:43:38 +0800 Subject: [PATCH] remove objc, add pom.xml to test C# petstore client --- pom.xml | 2 +- .../csharp/SwaggerClientTest/mono-nunit.sh | 14 +++++ .../petstore/csharp/SwaggerClientTest/pom.xml | 56 +++++++++++++++++++ 3 files changed, 71 insertions(+), 1 deletion(-) create mode 100755 samples/client/petstore/csharp/SwaggerClientTest/mono-nunit.sh create mode 100644 samples/client/petstore/csharp/SwaggerClientTest/pom.xml diff --git a/pom.xml b/pom.xml index 8e7aa5bf3c99..3519ce9f0cbb 100644 --- a/pom.xml +++ b/pom.xml @@ -473,7 +473,7 @@ samples/server/petstore/spring-mvc samples/client/petstore/ruby samples/server/petstore/jaxrs - samples/client/petstore/objc/SwaggerClientTests + diff --git a/samples/client/petstore/csharp/SwaggerClientTest/mono-nunit.sh b/samples/client/petstore/csharp/SwaggerClientTest/mono-nunit.sh new file mode 100755 index 000000000000..c14e76dad051 --- /dev/null +++ b/samples/client/petstore/csharp/SwaggerClientTest/mono-nunit.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env bash +wget -nc https://nuget.org/nuget.exe; +mozroots --import --sync + +# remove bin/Debug/SwaggerClientTest.dll +rm bin/Debug/SwaggerClientTest.dll 2> /dev/null + +# install NUnit runners via NuGet +mono nuget.exe install NUnit.Runners -Version 2.6.4 -OutputDirectory testrunner + +# build the solution and run the unit test +xbuild SwaggerClientTest.sln && \ +mono ./testrunner/NUnit.Runners.2.6.4/tools/nunit-console.exe bin/Debug/SwaggerClientTest.dll + diff --git a/samples/client/petstore/csharp/SwaggerClientTest/pom.xml b/samples/client/petstore/csharp/SwaggerClientTest/pom.xml new file mode 100644 index 000000000000..46304c216210 --- /dev/null +++ b/samples/client/petstore/csharp/SwaggerClientTest/pom.xml @@ -0,0 +1,56 @@ + + 4.0.0 + com.wordnik + CsharpPetstoreClientTests + pom + 1.0-SNAPSHOT + C# Swagger Petstore Client + + + + maven-dependency-plugin + + + package + + copy-dependencies + + + ${project.build.directory} + + + + + + org.codehaus.mojo + exec-maven-plugin + 1.2.1 + + + + mono-test + integration-test + + exec + + + mono-nunit.sh + + + + + + +