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('business_type__list','{}'::text[]);

    -- Run tests

    INSERT INTO business (description) values ('testing');

    PREPARE test AS SELECT count(*) > 0 from business_type__list()
                    WHERE description = 'testing';
    SELECT results_eq('test',ARRAY[true],'Business Class Inserted');
    DEALLOCATE test;

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

ROLLBACK;
