mini\Test\SqlLogicTest class

Documentation

SQLLogicTest parser and runner

Parses and executes SQLLogicTest format files (.test) against any DatabaseInterface. See: https://www.sqlite.org/sqllogictest/doc/trunk/about.wiki

Usage: $runner = new SqlLogicTest($pdo, $vdb); $results = $runner->runFile('path/to/test.test');

Properties (11)

private array $backends
private int $hashThreshold
private bool $stopOnError
private bool $verbose
private bool $printQuery
private bool $printResults
private bool $printErrors
private ?string $includeQueryPattern
private ?string $excludeQueryPattern
private array $halted
private array $lastQueryResults

Methods (28)

Documentation missing

Register a backend to test against

Stop on first error (useful for debugging)

Enable verbose mode - print each query to STDERR before running

Print each query before running it

Print actual result rows from each backend (not normalized/hashed)

Print VDB exceptions and parse errors

Only run queries matching regex pattern (ECMA style, case-insensitive)

Skip queries matching regex pattern (ECMA style, case-insensitive)

Check if SQL matches query filters

Run a .test file and return results

Run test content

Parse test file into records

Documentation missing

Documentation missing

Documentation missing

Print detailed comparison for stop-on-error mode

Documentation missing

Documentation missing

Print result rows as a table

Documentation missing

Sort results according to SQLLogicTest sort mode

Format query results according to SQLLogicTest conventions

Documentation missing

Documentation missing

Documentation missing

Documentation missing

Documentation missing

Source

src/Test/SqlLogicTest.php:17-676