public function BaseTest::setUp in TMGMT Extension Suite 8.2
Overrides TMGMTKernelTestBase::setUp
File
- tests/
src/ Kernel/ BaseTest.php, line 29
Class
- BaseTest
- TMGMT Extension Suit kernel test base class.
Namespace
Drupal\Tests\tmgmt_extension_suit\KernelCode
public function setUp() {
parent::setUp();
// Suppress deprecation errors.
set_error_handler(function ($errno) {
if ($errno == E_USER_DEPRECATED) {
return TRUE;
}
return FALSE;
});
$this->checkStatusQueue = \Drupal::service('queue')
->get('tmgmt_extension_suit_check_status');
$this->uniqueQueueItemMock = $this
->getMockBuilder('\\Drupal\\tmgmt_extension_suit\\Utils\\UniqueQueueItem')
->setMethods([
'addItem',
])
->disableOriginalConstructor()
->getMock();
\Drupal::getContainer()
->set('tmgmt_extension_suit.utils.queue_unique_item', $this->uniqueQueueItemMock);
$this
->installConfig([
'tmgmt_extension_suit',
]);
$this
->createJobWithItems([]);
$this->requestTime = time();
}