<?php
+use MediaWiki\Block\DatabaseBlock;
use MediaWiki\Block\Restriction\PageRestriction;
use MediaWiki\Block\SystemBlock;
use MediaWiki\MediaWikiServices;
$prev = time();
$now = time() + 120;
$this->user->mBlockedby = $this->user->getId();
- $this->user->mBlock = new Block( [
+ $this->user->mBlock = new DatabaseBlock( [
'address' => '127.0.8.1',
'by' => $this->user->getId(),
'reason' => 'no reason given',
global $wgLocalTZoffset;
$wgLocalTZoffset = -60;
$this->user->mBlockedby = $this->user->getName();
- $this->user->mBlock = new Block( [
+ $this->user->mBlock = new DatabaseBlock( [
'address' => '127.0.8.1',
'by' => $this->user->getId(),
'reason' => 'no reason given',
// partial block message test
$this->user->mBlockedby = $this->user->getName();
- $this->user->mBlock = new Block( [
+ $this->user->mBlock = new DatabaseBlock( [
'address' => '127.0.8.1',
'by' => $this->user->getId(),
'reason' => 'no reason given',
$now = time();
$this->user->mBlockedby = $this->user->getName();
- $this->user->mBlock = new Block( [
+ $this->user->mBlock = new DatabaseBlock( [
'address' => '127.0.8.1',
'by' => $this->user->getId(),
'reason' => 'no reason given',