Skip to content

Commit

Permalink
Merge pull request OpenAPITools#2939 from wing328/php_enum_test
Browse files Browse the repository at this point in the history
[PHP] add enum test in PHP API client
  • Loading branch information
wing328 committed May 23, 2016
2 parents 6c33552 + 7b1cfde commit 8ba19f0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ public static function tearDownAfterClass()
*/
public function testEnumClass()
{

$this->assertSame(Swagger\Client\Model\EnumClass::ABC, "_abc");
$this->assertSame(Swagger\Client\Model\EnumClass::EFG, "-efg");
$this->assertSame(Swagger\Client\Model\EnumClass::XYZ, "(xyz)");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@ public static function tearDownAfterClass()
*/
public function testEnumTest()
{

$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_STRING_UPPER, "UPPER");
$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_STRING_LOWER, "lower");
$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_INTEGER_1, 1);
$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_INTEGER_MINUS_1, -1);
$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_NUMBER_1_DOT_1, 1.1);
$this->assertSame(Swagger\Client\Model\EnumTest::ENUM_NUMBER_MINUS_1_DOT_2, -1.2);
}
}

0 comments on commit 8ba19f0

Please sign in to comment.