diff options
author | Igor Babaev <igor@askmonty.org> | 2017-08-10 16:23:26 -0700 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2017-08-10 16:23:26 -0700 |
commit | 5a71e6bd5a61dff6d549d2c4f5927bbbd7ebcfee (patch) | |
tree | 98ca05164f4a2bf2fce6e1644bc6335193e69bbd /mysql-test/t/gis-json.test | |
parent | 1710dd2bf286f9a240f380925a0067c57c1b29f9 (diff) | |
parent | bf75dcac89d1496032015526dc6ce78d327e329f (diff) | |
download | mariadb-git-bb-10-ext-mdev-13369.tar.gz |
Merge branch 'bb-10.2-ext' into bb-10-ext-mdev-13369bb-10-ext-mdev-13369
# Conflicts:
# mysql-test/r/derived_cond_pushdown.result
# mysql-test/t/derived_cond_pushdown.test
# sql/sql_derived.cc
# sql/sql_select.cc
# sql/sql_select.h
Diffstat (limited to 'mysql-test/t/gis-json.test')
-rw-r--r-- | mysql-test/t/gis-json.test | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/mysql-test/t/gis-json.test b/mysql-test/t/gis-json.test index 645c21bf011..5e695fbca9c 100644 --- a/mysql-test/t/gis-json.test +++ b/mysql-test/t/gis-json.test @@ -23,6 +23,23 @@ SELECT st_astext(st_geomfromgeojson('{"type""point"}')); SELECT st_astext(st_geomfromgeojson('{ "type": "Feature", "geometry": { "type": "Point", "coordinates": [102.0, 0.5] } }')); SELECT st_astext(st_geomfromgeojson('{ "type": "FeatureCollection", "features": [{ "type": "Feature", "geometry": { "type": "Point", "coordinates": [102.0, 0.5] }, "properties": { "prop0": "value0" } }]}')); +--error ER_WRONG_VALUE_FOR_TYPE +SELECT ST_AsText(ST_GeomFromGeoJSON('{ "type": "Point", "coordinates": [5.3, 15.0, 4.3]}',5)); + +--error ER_GIS_INVALID_DATA +SELECT ST_AsText(ST_GeomFromGeoJSON('{ "type": "Point", "coordinates": [5.3, 15.0, 4.3]}',1)); + +SELECT ST_AsText(ST_GeomFromGeoJSON('{ "type": "Point", "coordinates": [5.3, 15.0, 4.3]}',2)); +SELECT ST_AsText(ST_GeomFromGeoJSON('{ "type": "Point", "coordinates": [5.3, 15.0, 4.3]}',3)); +SELECT ST_AsText(ST_GeomFromGeoJSON('{ "type": "Point", "coordinates": [5.3, 15.0, 4.3]}',4)); + +SELECT ST_AsGeoJSON(ST_GeomFromText('POINT(5.363 7.266)'),2); +SELECT ST_AsGeoJSON(ST_GeomFromText('POINT(5.363 7.266)'),1); +SELECT ST_AsGeoJSON(ST_GeomFromText('POINT(5.363 7.266)'),10); + +SELECT ST_AsGeoJSON(ST_GeomFromText("POINT(10 11)"), 100, 1); +SELECT ST_AsGeoJSON(ST_GeomFromText("POINT(10 11)"), 100, 5); + --echo # --echo # End of 10.2 tests --echo # |