You are here

protected function SubmissionsCompletedSinceLastSuccessTest::createTestSubmission in Webform Scheduled Tasks 8.2

Create a test submission.

3 calls to SubmissionsCompletedSinceLastSuccessTest::createTestSubmission()
SubmissionsCompletedSinceLastSuccessTest::testAllResultsAreIncludedForFailedTask in tests/src/Kernel/SubmissionsCompletedSinceLastSuccessTest.php
@covers ::getResultSet
SubmissionsCompletedSinceLastSuccessTest::testBasicIncrementalSubmissions in tests/src/Kernel/SubmissionsCompletedSinceLastSuccessTest.php
@covers ::getResultSet
SubmissionsCompletedSinceLastSuccessTest::testSubmissionCreationTimeScheduleRaceConditions in tests/src/Kernel/SubmissionsCompletedSinceLastSuccessTest.php
@covers ::getResultSet

File

tests/src/Kernel/SubmissionsCompletedSinceLastSuccessTest.php, line 199

Class

SubmissionsCompletedSinceLastSuccessTest
Submissions since last success result set plugin test.

Namespace

Drupal\Tests\webform_scheduled_tasks\Kernel

Code

protected function createTestSubmission($fields = []) {
  $submission = WebformSubmission::create($fields + [
    'webform_id' => 'scheduled_webform',
  ]);
  $submission
    ->save();
  return $submission;
}