Skip to content

Commit

Permalink
Merge pull request #21146 from demeritcowboy/smarty-default-caserole
Browse files Browse the repository at this point in the history
[NFC] Update testCaseActivityCopyTemplate to provide variable that would usually be present
  • Loading branch information
eileenmcnaughton authored Aug 15, 2021
2 parents 199c995 + ea0e124 commit 1cae999
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/phpunit/CRM/Core/BAO/MessageTemplateTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ public function testCaseActivityCopyTemplate():void {
],
'activitySubject' => 'Test 123',
'idHash' => substr(sha1(CIVICRM_SITE_KEY . '1234'), 0, 7),
'contact' => ['role' => 'Sand grain counter'],
];

[, $subject, $message] = CRM_Core_BAO_MessageTemplate::sendTemplate(
Expand All @@ -192,7 +193,7 @@ public function testCaseActivityCopyTemplate():void {
);

$this->assertEquals('[case #' . $tplParams['idHash'] . '] Test 123', $subject);
$this->assertStringContainsString('Your Case Role', $message);
$this->assertStringContainsString('Your Case Role(s) : Sand grain counter', $message);
$this->assertStringContainsString('Case ID : 1234', $message);
}

Expand Down

0 comments on commit 1cae999

Please sign in to comment.