diff schema/gemma_tests.sql @ 4602:9fef9930aa8a geoserver_sql_views

Add field for GeoServer SQL view definition
author Tom Gottfried <tom@intevation.de>
date Mon, 02 Sep 2019 18:45:15 +0200
parents b785b6bef578
children d24e951206ca
line wrap: on
line diff
--- a/schema/gemma_tests.sql	Mon Sep 02 18:38:27 2019 +0200
+++ b/schema/gemma_tests.sql	Mon Sep 02 18:45:15 2019 +0200
@@ -15,6 +15,12 @@
 -- pgTAP test script for gemma schema definition
 --
 
+SELECT ok(is_valid_from_item('SELECT * FROM sys_admin.published_services'),
+    'Valid statement passes check');
+
+SELECT ok(NOT is_valid_from_item('This is not SQL'),
+    'Arbitrary text does not pass check');
+
 SELECT throws_ok($$
     INSERT INTO waterway.waterway_axis (wtwaxs, objnam) VALUES
         (ST_GeogFromText('LINESTRING(0 0, 1 1)'), 'test'),