Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API Rescue Master Branch PR: TestCase classes should be abstract to prevent warnings #10461

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Dev/FunctionalTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
* }
* </code>
*/
class FunctionalTest extends SapphireTest implements TestOnly
abstract class FunctionalTest extends SapphireTest implements TestOnly
{
/**
* Set this to true on your sub-class to disable the use of themes in this test.
Expand Down
7 changes: 1 addition & 6 deletions src/Dev/SapphireTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
* This class should not be used anywhere outside of unit tests, as phpunit may not be installed
* in production sites.
*/
class SapphireTest extends TestCase implements TestOnly
abstract class SapphireTest extends TestCase implements TestOnly
{
/**
* Path to fixture data for this test run.
Expand Down Expand Up @@ -274,11 +274,6 @@ protected function setUp(): void
// Call state helpers
static::$state->setUp($this);

// We cannot run the tests on this abstract class.
if (static::class == __CLASS__) {
$this->markTestSkipped(sprintf('Skipping %s ', static::class));
}

// i18n needs to be set to the defaults or tests fail
if (class_exists(i18n::class)) {
i18n::set_locale(i18n::config()->uninherited('default_locale'));
Expand Down