-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use sensible names, and also fix a few bug discovered by altering the tests with more data and cases (such as the SQLDelete statement). CVE DataObject is now SecurityAlerts, as not all alerts are assigned CVE identifiers. To that end if there is another identifier (such as the one SilverStripe use as a title prefix) then this is set instead. As such the property is renamed 'Identifier' as opposed to 'CVE'.
- Loading branch information
Dylan Wagstaff
committed
May 31, 2018
1 parent
a8e9238
commit 0196327
Showing
12 changed files
with
221 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/Extensions/CVEExtension.php → src/Extensions/SecurityAlertExtension.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
class SecurityAlertCheckJobTest extends SapphireTest | ||
{ | ||
public function testJobCallsTask() | ||
{ | ||
$spy = $this->getMockBuilder(SecurityAlertCheckTask::class)->setMethods(['run'])->getMock(); | ||
$spy->expects($this->once())->method('run'); | ||
|
||
$job = new SecurityAlertCheckJob; | ||
$job->setCheckTask($spy); | ||
|
||
$job->process(); | ||
} | ||
} |
Oops, something went wrong.