Skip to content

Commit

Permalink
API phpunit 9 support
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed Oct 21, 2021
1 parent ee9206e commit 70281b7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@
}
],
"require": {
"silverstripe/framework": "^4.4@dev",
"silverstripe/framework": "^4.10",
"silverstripe/cms": "^4.4@dev"
},
"require-dev": {
"sminnee/phpunit": "^5.7",
"phpunit/phpunit": "^9",
"squizlabs/php_codesniffer": "^3.0"
},
"extra": {
Expand Down
8 changes: 5 additions & 3 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
<phpunit bootstrap="vendor/silverstripe/cms/tests/bootstrap.php" colors="true">
<testsuite name="Default">
<directory>tests</directory>
</testsuite>
<testsuites>
<testsuite name="Default">
<directory>tests</directory>
</testsuite>
</testsuites>

<filter>
<whitelist addUncoveredFilesFromWhitelist="true">
Expand Down
4 changes: 2 additions & 2 deletions tests/ShareDraftContentSiteTreeExtensionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public function testShareTokenLink()
$controller = new ShareDraftController();
$response = $controller->preview($request);

$this->assertContains('share-draft-content-message', $response);
$this->assertStringContainsString('share-draft-content-message', $response);

$request = new HTTPRequest('GET', $firstShareLink);

Expand All @@ -89,6 +89,6 @@ public function testShareTokenLink()
$controller = new ShareDraftController();
$response = $controller->preview($request);

$this->assertContains('share-draft-error-page', $response);
$this->assertStringContainsString('share-draft-error-page', $response);
}
}

0 comments on commit 70281b7

Please sign in to comment.