@@ 40-52 (lines=13) @@ | ||
37 | $this->assertFileExists('/tmp/Export of TestForm - 2018-01-01 12:00:00.csv'); |
|
38 | } |
|
39 | ||
40 | public function testIsSend() |
|
41 | { |
|
42 | $submission = $this->objFromFixture(PartialFormSubmission::class, 'submission1'); |
|
43 | $config = SiteConfig::current_site_config(); |
|
44 | $config->SendDailyEmail = true; |
|
45 | $config->SendMailTo = '[email protected]'; |
|
46 | $config->write(); |
|
47 | $this->job->process(); |
|
48 | ||
49 | $processedSubmission = $submission->get()->byID($submission->ID); |
|
50 | ||
51 | $this->assertTrue($processedSubmission->IsSend); |
|
52 | } |
|
53 | ||
54 | public function testIsDeleted() |
|
55 | { |
|
@@ 54-68 (lines=15) @@ | ||
51 | $this->assertTrue($processedSubmission->IsSend); |
|
52 | } |
|
53 | ||
54 | public function testIsDeleted() |
|
55 | { |
|
56 | $submission = $this->objFromFixture(PartialFormSubmission::class, 'submission1'); |
|
57 | $config = SiteConfig::current_site_config(); |
|
58 | $config->SendDailyEmail = true; |
|
59 | $config->CleanupAfterSend = true; |
|
60 | $config->SendMailTo = '[email protected]'; |
|
61 | $config->write(); |
|
62 | $this->job->process(); |
|
63 | ||
64 | $processedSubmission = $submission->get()->byID($submission->ID); |
|
65 | ||
66 | $this->assertNull($processedSubmission); |
|
67 | ||
68 | } |
|
69 | ||
70 | protected function setUp() |
|
71 | { |