public function JobTest::testCreate in Advanced Queue 8
@covers ::create @covers ::getType @covers ::getPayload @covers ::getState
File
- tests/
src/ Unit/ JobTest.php, line 20
Class
- JobTest
- @coversDefaultClass \Drupal\advancedqueue\Job @group advancedqueue
Namespace
Drupal\Tests\advancedqueue\UnitCode
public function testCreate() {
$job = Job::create('test', [
'my' => 'data',
]);
$this
->assertEquals('test', $job
->getType());
$this
->assertEquals([
'my' => 'data',
], $job
->getPayload());
$this
->assertEquals(Job::STATE_QUEUED, $job
->getState());
}