ApiRevisionDeleteTest: Use registered authority for tests
Why: - Anon authority will generate manual log entries with an anonymous actor, which won't work with temp accounts enabled What: - Switch test cases to use registered authority mock Bug: T365669 Change-Id: I4d3a79506d2f1fc744fc32b75e560f084738bdd7
This commit is contained in:
parent
534ecdd49c
commit
a64e3d6c3a
1 changed files with 2 additions and 2 deletions
|
|
@ -33,7 +33,7 @@ class ApiRevisionDeleteTest extends ApiTestCase {
|
|||
}
|
||||
|
||||
public function testHidingRevisions() {
|
||||
$performer = $this->mockAnonAuthorityWithPermissions( [ 'writeapi', 'deleterevision' ] );
|
||||
$performer = $this->mockRegisteredAuthorityWithPermissions( [ 'writeapi', 'deleterevision' ] );
|
||||
$revid = array_shift( $this->revs );
|
||||
$out = $this->doApiRequestWithToken( [
|
||||
'action' => 'revisiondelete',
|
||||
|
|
@ -93,7 +93,7 @@ class ApiRevisionDeleteTest extends ApiTestCase {
|
|||
}
|
||||
|
||||
public function testUnhidingOutput() {
|
||||
$performer = $this->mockAnonAuthorityWithPermissions( [ 'writeapi', 'deleterevision' ] );
|
||||
$performer = $this->mockRegisteredAuthorityWithPermissions( [ 'writeapi', 'deleterevision' ] );
|
||||
$revid = array_shift( $this->revs );
|
||||
// Hide revisions
|
||||
$this->doApiRequestWithToken( [
|
||||
|
|
|
|||
Loading…
Reference in a new issue