Beispiel #1
0
 /**
  * @param string $data
  * @param string $expected
  * @param null|array $allowedTags
  * @dataProvider escapeHtmlDataProvider
  */
 public function testEscapeHtml($data, $expected, $allowedTags = null)
 {
     $this->adminHelperMock->expects($this->any())->method('escapeHtmlWithLinks')->will($this->returnValue($expected));
     $actual = $this->commentsView->escapeHtml($data, $allowedTags);
     $this->assertEquals($expected, $actual);
 }
 public function testGetItemCommentIsNotSet()
 {
     $item = [];
     $this->adminHelperMock->expects($this->never())->method('escapeHtmlWithLinks');
     $this->assertEquals('', $this->commentsHistory->getItemComment($item));
 }