You are here

public function SmsFrameworkMessageTestTrait::testSender in SMS Framework 8

Same name and namespace in other branches
  1. 2.x tests/src/Functional/SmsFrameworkMessageTestTrait.php \Drupal\Tests\sms\Functional\SmsFrameworkMessageTestTrait::testSender()
  2. 2.1.x tests/src/Functional/SmsFrameworkMessageTestTrait.php \Drupal\Tests\sms\Functional\SmsFrameworkMessageTestTrait::testSender()

Tests sender name.

File

tests/src/Functional/SmsFrameworkMessageTestTrait.php, line 23

Class

SmsFrameworkMessageTestTrait
SMS Message object test trait.

Namespace

Drupal\Tests\sms\Functional

Code

public function testSender() {
  $sender = $this
    ->randomMachineName();
  $sms_message = $this
    ->createSmsMessage();
  $sms_message
    ->setSender($sender);
  $this
    ->assertEquals($sender, $sms_message
    ->getSender());
}