NAME

DBIO::DuckDB::Test - DuckDB-specific test utilities for DBIO

VERSION

version 0.900000

SYNOPSIS

use DBIO::DuckDB::Test;

my $schema = DBIO::DuckDB::Test->init_schema;
my $rs = $schema->resultset('Artist');

DESCRIPTION

Extends DBIO::Test with DuckDB-specific test helpers for the DBIO::DuckDB driver distribution. Mirrors DBIO::SQLite::Test: driver tests call DBIO::DuckDB::Test->init_schema and get a connected, deployed schema backed by an in-memory DuckDB.

METHODS

_database

Returns ($dsn, $user, $pass, \%opts) for $schema->connect(). Honours DBIO_TEST_DUCKDB_DSN if set, otherwise uses dbi:DuckDB:dbname=:memory:.

init_schema

my $schema = DBIO::DuckDB::Test->init_schema(%opts);

Thin wrapper around "init_schema" in DBIO::Test. Fills in dsn and storage_type for DuckDB (honouring DBIO_TEST_DUCKDB_DSN) and then delegates to the core harness.

Core's deploy_schema calls $schema->deploy, which "deploy" in DBIO::Schema routes through dbio_deploy_class when set on the storage class -- so DuckDB deployment goes through DBIO::DuckDB::Deploy (the native test-and-compare path), not SQL::Translator. No extra install step needed here.

AUTHOR

DBIO Authors

COPYRIGHT AND LICENSE

Copyright (C) 2026 DBIO Authors

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.