You are here

private function JsonLogTest::getEmptyMessageParserMock in JSONlog 8

Same name and namespace in other branches
  1. 8.2 tests/src/Unit/JsonLogTest.php \Drupal\Tests\jsonlog\Unit\JsonLogTest::getEmptyMessageParserMock()
  2. 3.x tests/src/Unit/JsonLogTest.php \Drupal\Tests\jsonlog\Unit\JsonLogTest::getEmptyMessageParserMock()

Return value

\PHPUnit\Framework\MockObject\MockObject

1 call to JsonLogTest::getEmptyMessageParserMock()
JsonLogTest::setUp in tests/src/Unit/JsonLogTest.php

File

tests/src/Unit/JsonLogTest.php, line 123

Class

JsonLogTest
Unit tests for JsonLog class

Namespace

Drupal\Tests\jsonlog\Unit

Code

private function getEmptyMessageParserMock() {
  $messageParserMock = $this
    ->createMock('Drupal\\Core\\Logger\\LogMessageParserInterface');
  $messageParserMock
    ->expects($this
    ->atMost(1))
    ->method('parseMessagePlaceholders')
    ->withAnyParameters()
    ->willReturn([]);
  return $messageParserMock;
}