protected function setUp(): void
{ parent::
setUp();
$this->stringTranslation =
$this->
createMock('Drupal\Core\StringTranslation\TranslationInterface'
);
} /**
* Sets up the breakpoint defaults.
*/
protected function setupBreakpoint() { $this->breakpoint =
new Breakpoint([],
$this->pluginId,
$this->pluginDefinition
);
$this->breakpoint->
setStringTranslation($this->stringTranslation
);
} /**
* @covers ::getLabel
*/
public function testGetLabel() { $this->pluginDefinition
['label'
] = 'Test label';
$this->
setupBreakpoint();
$this->
assertEquals(new TranslatableMarkup('Test label',
[],
['context' => 'breakpoint'
],
$this->stringTranslation
),
$this->breakpoint->
getLabel());
}