From 04176cd9db311b19f77e99d150b48500fe9e373d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Tue, 18 Jan 2022 15:39:44 -0300 Subject: [PATCH] Mark test as incomplete for not supported queries MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Instead of printing the query, it marks the test as incomplete, this way we have a stack trace that help finding why it happened. Signed-off-by: MaurĂ­cio Meneghini Fauth --- test/classes/Stubs/DbiDummy.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/test/classes/Stubs/DbiDummy.php b/test/classes/Stubs/DbiDummy.php index 261f774c0123..dede9331ea36 100644 --- a/test/classes/Stubs/DbiDummy.php +++ b/test/classes/Stubs/DbiDummy.php @@ -15,6 +15,7 @@ use PhpMyAdmin\Dbal\DbiExtension; use PhpMyAdmin\Dbal\ResultInterface; use PhpMyAdmin\FieldMetadata; +use PHPUnit\Framework\Assert; use function addslashes; use function count; @@ -239,9 +240,7 @@ public function realQuery(string $query, $link, int $options) return new DummyResult($this, $i + self::OFFSET_GLOBAL); } - echo 'Not supported query: ' . $query . "\n"; - - return false; + Assert::markTestIncomplete('Not supported query: ' . $query); } /**