Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions src/KernelishBase.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,50 @@
{
}

/**
* {@inheritdoc}
*/
public function tearDown(): void
{
$has_failed = false;
// For phpunit <= 9:
if (method_exists($this, 'hasFailed')) {

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^8)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.

Check failure on line 38 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^9)

Call to function method_exists() with $this(frontkom\DttKernelishBase\KernelishBase) and 'hasFailed' will always evaluate to true.
$has_failed = $this->hasFailed();
}
$database = $this->container->get('database');

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.3, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (7.4, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.2, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.1, ^8)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.

Check failure on line 41 in src/KernelishBase.php

View workflow job for this annotation

GitHub Actions / Run tests (8.4, ^9)

Call to method get() on an unknown class Symfony\Component\DependencyInjection\ContainerInterface.
if ($has_failed) {
if ($database->schema()->tableExists('watchdog')) {
$messages = $database
->select('watchdog', 'w')
->fields('w')
->orderBy('w.wid', 'DESC')
->range(0, 10)
->execute()
->fetchAll();
if (!empty($messages)) {
foreach ($messages as $error) {
// Perform replacements so the error message is easier to
// read in the log.
// @codingStandardsIgnoreLine
$error->variables = unserialize($error->variables);
$error->message = str_replace(
array_keys($error->variables),
$error->variables,
$error->message
);
unset($error->variables);
print_r($error);
}
}
} else {
// Print a warning if the watchdog table does not exist.
print_r('Watchdog table does not exist. Please check your test environment.');
}
}
parent::tearDown();
}


/**
* {@inheritdoc}
*/
Expand Down
Loading