Skip to content

Commit 8b39335

Browse files
authored
fix php test using getter (#7525)
1 parent 7a98580 commit 8b39335

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

samples/client/petstore/php/OpenAPIClient-php/tests/PetApiTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,21 +114,21 @@ public function testGetPetByIdWithHttpInfo()
114114
$this->assertSame($status_code, 200);
115115
$this->assertSame($response_headers['Content-Type'], ['application/json']);
116116
}
117-
/* comment out due to https://github.com/OpenAPITools/openapi-generator/pull/7376#issuecomment-699722244
117+
118118
public function testFindPetByStatus()
119119
{
120120
$response = $this->api->findPetsByStatus('available');
121121
$this->assertGreaterThan(0, count($response)); // at least one object returned
122122

123123
$this->assertSame(get_class($response[0]), Pet::class); // verify the object is Pet
124124
foreach ($response as $pet) {
125-
$this->assertSame($pet['status'], 'available');
125+
$this->assertSame($pet->getStatus(), 'available');
126126
}
127127

128128
$response = $this->api->findPetsByStatus('unknown_and_incorrect_status');
129129
$this->assertCount(0, $response);
130130
}
131-
*/
131+
132132
public function testUpdatePet()
133133
{
134134
$petId = 10001;

0 commit comments

Comments
 (0)