diff --git a/bin/php-petstore.sh b/bin/php-petstore.sh index 98a8dc708aa..a7d618e44eb 100755 --- a/bin/php-petstore.sh +++ b/bin/php-petstore.sh @@ -24,6 +24,12 @@ then mvn clean package fi +# cleanup tests +TEST_DIR="./samples/client/petstore/php/SwaggerClient-php/test" +if [ -d $TEST_DIR ]; then + rm -rf $TEST_DIR +fi + # if you've executed sbt assembly previously it will use that instead. export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties" ags="generate -t modules/swagger-codegen/src/main/resources/php -i modules/swagger-codegen/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -l php -o samples/client/petstore/php $@" diff --git a/bin/security/php-petstore.sh b/bin/security/php-petstore.sh index 51b61127dd2..ce5872e8a77 100755 --- a/bin/security/php-petstore.sh +++ b/bin/security/php-petstore.sh @@ -24,6 +24,12 @@ then mvn clean package fi +# cleanup tests +TEST_DIR="./samples/client/petstore-security-test/php/SwaggerClient-php/test" +if [ -d $TEST_DIR ]; then + rm -rf $TEST_DIR +fi + # if you've executed sbt assembly previously it will use that instead. export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties" ags="$@ generate -t modules/swagger-codegen/src/main/resources/php -i modules/swagger-codegen/src/test/resources/2_0/petstore-security-test.yaml -l php -o samples/client/petstore-security-test/php" diff --git a/samples/client/petstore-security-test/php/SwaggerClient-php/test/Api/FakeApiTest.php b/samples/client/petstore-security-test/php/SwaggerClient-php/test/Api/FakeApiTest.php index 732f8487b59..613e83d2089 100644 --- a/samples/client/petstore-security-test/php/SwaggerClient-php/test/Api/FakeApiTest.php +++ b/samples/client/petstore-security-test/php/SwaggerClient-php/test/Api/FakeApiTest.php @@ -5,31 +5,19 @@ * * @category Class * @package Swagger\Client - * @author http://github.com/swagger-api/swagger-codegen - * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License v2 + * @author Swagger Codegen team * @link https://github.com/swagger-api/swagger-codegen */ /** - * Swagger Petstore *_/ ' \" =end \\r\\n \\n \\r + * Swagger Petstore *_/ ' \" =end -- \\r\\n \\n \\r * - * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ *_/ ' \" =end + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ *_/ ' \" =end -- * - * OpenAPI spec version: 1.0.0 *_/ ' \" =end \\r\\n \\n \\r - * Contact: apiteam@swagger.io *_/ ' \" =end \\r\\n \\n \\r + * OpenAPI spec version: 1.0.0 *_/ ' \" =end -- \\r\\n \\n \\r + * Contact: apiteam@swagger.io *_/ ' \" =end -- \\r\\n \\n \\r * Generated by: https://github.com/swagger-api/swagger-codegen.git - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Swagger Codegen version: 2.4.0-SNAPSHOT */ /** @@ -41,7 +29,6 @@ namespace Swagger\Client; use \Swagger\Client\Configuration; -use \Swagger\Client\ApiClient; use \Swagger\Client\ApiException; use \Swagger\Client\ObjectSerializer; @@ -50,8 +37,7 @@ use \Swagger\Client\ObjectSerializer; * * @category Class * @package Swagger\Client - * @author http://github.com/swagger-api/swagger-codegen - * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License v2 + * @author Swagger Codegen team * @link https://github.com/swagger-api/swagger-codegen */ class FakeApiTest extends \PHPUnit_Framework_TestCase @@ -62,7 +48,6 @@ class FakeApiTest extends \PHPUnit_Framework_TestCase */ public static function setUpBeforeClass() { - } /** @@ -70,7 +55,6 @@ class FakeApiTest extends \PHPUnit_Framework_TestCase */ public function setUp() { - } /** @@ -78,7 +62,6 @@ class FakeApiTest extends \PHPUnit_Framework_TestCase */ public function tearDown() { - } /** @@ -86,18 +69,15 @@ class FakeApiTest extends \PHPUnit_Framework_TestCase */ public static function tearDownAfterClass() { - } /** * Test case for testCodeInjectEndRnNR * - * To test code injection *_/ ' \" =end \\r\\n \\n \\r. + * To test code injection *_/ ' \" =end -- \\r\\n \\n \\r. * */ public function testTestCodeInjectEndRnNR() { - } - } diff --git a/samples/client/petstore-security-test/php/SwaggerClient-php/test/Model/ModelReturnTest.php b/samples/client/petstore-security-test/php/SwaggerClient-php/test/Model/ModelReturnTest.php index c4c8dbe6dd7..b49dc30a4e0 100644 --- a/samples/client/petstore-security-test/php/SwaggerClient-php/test/Model/ModelReturnTest.php +++ b/samples/client/petstore-security-test/php/SwaggerClient-php/test/Model/ModelReturnTest.php @@ -6,31 +6,19 @@ * * @category Class * @package Swagger\Client - * @author http://github.com/swagger-api/swagger-codegen - * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License v2 + * @author Swagger Codegen team * @link https://github.com/swagger-api/swagger-codegen */ /** - * Swagger Petstore *_/ ' \" =end \\r\\n \\n \\r + * Swagger Petstore *_/ ' \" =end -- \\r\\n \\n \\r * - * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ *_/ ' \" =end + * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ *_/ ' \" =end -- * - * OpenAPI spec version: 1.0.0 *_/ ' \" =end \\r\\n \\n \\r - * Contact: apiteam@swagger.io *_/ ' \" =end \\r\\n \\n \\r + * OpenAPI spec version: 1.0.0 *_/ ' \" =end -- \\r\\n \\n \\r + * Contact: apiteam@swagger.io *_/ ' \" =end -- \\r\\n \\n \\r * Generated by: https://github.com/swagger-api/swagger-codegen.git - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. + * Swagger Codegen version: 2.4.0-SNAPSHOT */ /** @@ -44,12 +32,10 @@ namespace Swagger\Client; /** * ModelReturnTest Class Doc Comment * - * @category Class */ -// * @description Model for testing reserved words *_/ ' \" =end \\r\\n \\n \\r -/** + * @category Class + * @description Model for testing reserved words *_/ ' \" =end -- \\r\\n \\n \\r * @package Swagger\Client - * @author http://github.com/swagger-api/swagger-codegen - * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License v2 + * @author Swagger Codegen team * @link https://github.com/swagger-api/swagger-codegen */ class ModelReturnTest extends \PHPUnit_Framework_TestCase @@ -60,7 +46,6 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public static function setUpBeforeClass() { - } /** @@ -68,7 +53,6 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public function setUp() { - } /** @@ -76,7 +60,6 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public function tearDown() { - } /** @@ -84,7 +67,6 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public static function tearDownAfterClass() { - } /** @@ -92,7 +74,6 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public function testModelReturn() { - } /** @@ -100,7 +81,5 @@ class ModelReturnTest extends \PHPUnit_Framework_TestCase */ public function testPropertyReturn() { - } - }