From 604c4ed615dde2d66481da1189d90108bf36a16c Mon Sep 17 00:00:00 2001 From: Rafa de la Torre Date: Fri, 23 Oct 2015 14:19:41 +0200 Subject: [PATCH] Another basic test --- .../extension/expected/cdb_geocoder_admin0_test.out | 9 +++++++++ .../admin0/extension/sql/cdb_geocoder_admin0_test.sql | 3 +++ 2 files changed, 12 insertions(+) diff --git a/geocoder/admin0/extension/expected/cdb_geocoder_admin0_test.out b/geocoder/admin0/extension/expected/cdb_geocoder_admin0_test.out index 834ab14..92a15ff 100644 --- a/geocoder/admin0/extension/expected/cdb_geocoder_admin0_test.out +++ b/geocoder/admin0/extension/expected/cdb_geocoder_admin0_test.out @@ -11,3 +11,12 @@ SELECT (admin0_synonym_lookup(Array['United States', 'ESP'])).*; ESP | (2 rows) +-- Check that the geocoding function is callable, should return success = false +SELECT (geocode_admin0_polygons(Array['Spain', 'USA', ''])).*; + q | geom | success +-------+------+--------- + | | f + Spain | | f + USA | | f +(3 rows) + diff --git a/geocoder/admin0/extension/sql/cdb_geocoder_admin0_test.sql b/geocoder/admin0/extension/sql/cdb_geocoder_admin0_test.sql index c5fe53f..e782008 100644 --- a/geocoder/admin0/extension/sql/cdb_geocoder_admin0_test.sql +++ b/geocoder/admin0/extension/sql/cdb_geocoder_admin0_test.sql @@ -6,3 +6,6 @@ CREATE EXTENSION cdb_geocoder_admin0; -- Check that the synonym function is callable, should return NULL SELECT (admin0_synonym_lookup(Array['United States', 'ESP'])).*; + +-- Check that the geocoding function is callable, should return success = false +SELECT (geocode_admin0_polygons(Array['Spain', 'USA', ''])).*;