]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/src/sql/Pg/t/lp1464709-copy-stat-co-ok.pg
dfe9a991075b4c27941a420982e36db3305d7d6a
[working/Evergreen.git] / Open-ILS / src / sql / Pg / t / lp1464709-copy-stat-co-ok.pg
1 \set ECHO none
2 \set QUIET 1
3 -- Turn off echo and keep things quiet.
4
5 -- Format the output for nice TAP.
6 \pset format unaligned
7 \pset tuples_only true
8 \pset pager
9
10 -- Revert all changes on failure.
11 \set ON_ERROR_ROLLBACK 1
12 \set ON_ERROR_STOP true
13 \set QUIET 1
14
15 -- Load the TAP functions.
16 BEGIN;
17
18 -- Plan the tests.
19 SELECT plan(1);
20
21 -- ensures the column exists and seed data has been updated.
22 SELECT cmp_ok(
23     COUNT(*)::int, '>=', 3, 
24     'At least 3 copy status should be configured as "checkout_ok"') 
25     FROM config.copy_status WHERE checkout_ok;
26
27 -- Finish the tests and clean up.
28 SELECT * FROM finish();
29 ROLLBACK;