Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. TestLogger.php

function TestLogger::hasRecordThatContains

File

vendor/colinodell/psr-testlogger/src/TestLogger.php, line 116

Class

TestLogger
Used for testing purposes.

Namespace

ColinODell\PsrTestLogger

Code

public function hasRecordThatContains(string $message, string|int|null $level = null) : bool {
    return $this->hasRecordThatPasses(static function (array $rec) use ($message) {
        return \str_contains((string) $rec['message'], $message);
    }, $level);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal