BEGIN;
    -- Load the TAP functions.
    CREATE EXTENSION pgtap;

    -- Plan the tests.

    SELECT plan(3);

    -- Add data

    \i sql/modules/test/Base.sql

    -- Validate required tables

--    SELECT has_table('business');

    -- Validate required functions

    SELECT has_function('trial_balance__generate',ARRAY['date','date','integer','integer[]','text','integer[]','integer','boolean','boolean']);
    SELECT has_function('trial_balance__heading_accounts',ARRAY['integer[]']);
    SELECT has_function('trial_balance__list_headings','{}'::text[]);

    -- Run tests

--    PREPARE test AS select ...;
--    SELECT results_eq('test',result,'Description');
--    DEALLOCATE test;

    -- Finish the tests and clean up.
    SELECT * FROM finish();

ROLLBACK;
