mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2026-03-23 01:19:03 +00:00
refactor(php): use self::markTestIncomplete instead of instance calls (#17824)
It's reported by phpstan as `Dynamic call to static method PHPUnit\Framework\Assert::markTestIncomplete().`. The method is static, therefore it should not be called from instance context.
This commit is contained in:
@@ -70,7 +70,7 @@ use PHPUnit\Framework\TestCase;
|
||||
public function test{{vendorExtensions.x-test-operation-id}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{/operation}}
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@ class {{classname}}Test extends TestCase
|
||||
public function test{{classname}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{#vars}}
|
||||
|
||||
@@ -77,7 +77,7 @@ class {{classname}}Test extends TestCase
|
||||
public function testProperty{{nameInCamelCase}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{/vars}}
|
||||
}
|
||||
|
||||
@@ -62,7 +62,7 @@ class {{userClassname}}Test extends TestCase
|
||||
*/
|
||||
public function test{{operationIdCamelCase}}()
|
||||
{
|
||||
$this->markTestIncomplete(
|
||||
self::markTestIncomplete(
|
||||
'Test of "{{operationId}}" method has not been implemented yet.'
|
||||
);
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ class {{classname}}Test extends TestCase
|
||||
class_exists($namespacedClassname),
|
||||
sprintf('Assertion failed that "%s" class exists', $namespacedClassname)
|
||||
);
|
||||
$this->markTestIncomplete(
|
||||
self::markTestIncomplete(
|
||||
'Test of "{{classname}}" model has not been implemented yet.'
|
||||
);
|
||||
}
|
||||
@@ -76,7 +76,7 @@ class {{classname}}Test extends TestCase
|
||||
*/
|
||||
public function testProperty{{nameInCamelCase}}()
|
||||
{
|
||||
$this->markTestIncomplete(
|
||||
self::markTestIncomplete(
|
||||
'Test of "{{name}}" property in "{{classname}}" model has not been implemented yet.'
|
||||
);
|
||||
}
|
||||
@@ -92,4 +92,4 @@ class {{classname}}Test extends TestCase
|
||||
$this->assertIsArray($schemaArr);
|
||||
}
|
||||
}
|
||||
{{/model}}{{/models}}
|
||||
{{/model}}{{/models}}
|
||||
|
||||
@@ -72,7 +72,7 @@ use PHPUnit\Framework\TestCase;
|
||||
public function test{{vendorExtensions.x-test-operation-id}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{/operation}}
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ class {{classname}}Test extends TestCase
|
||||
public function test{{classname}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{#vars}}
|
||||
|
||||
@@ -79,7 +79,7 @@ class {{classname}}Test extends TestCase
|
||||
public function testProperty{{nameInCamelCase}}()
|
||||
{
|
||||
// TODO: implement
|
||||
$this->markTestIncomplete('Not implemented');
|
||||
self::markTestIncomplete('Not implemented');
|
||||
}
|
||||
{{/vars}}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user