You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by vo...@apache.org on 2019/02/14 12:17:54 UTC
[ignite] 02/05: Test fixes.
This is an automated email from the ASF dual-hosted git repository.
vozerov pushed a commit to branch ignite-11310-nodml
in repository https://gitbox.apache.org/repos/asf/ignite.git
commit 0a0cd44c045cf31b37f1d8a504247a37aaf7db30
Author: devozerov <vo...@gridgain.com>
AuthorDate: Thu Feb 14 13:23:16 2019 +0300
Test fixes.
---
.../query/h2/H2IndexingAbstractGeoSelfTest.java | 39 ----------------------
1 file changed, 39 deletions(-)
diff --git a/modules/geospatial/src/test/java/org/apache/ignite/internal/processors/query/h2/H2IndexingAbstractGeoSelfTest.java b/modules/geospatial/src/test/java/org/apache/ignite/internal/processors/query/h2/H2IndexingAbstractGeoSelfTest.java
index 423f714..ddf1344 100644
--- a/modules/geospatial/src/test/java/org/apache/ignite/internal/processors/query/h2/H2IndexingAbstractGeoSelfTest.java
+++ b/modules/geospatial/src/test/java/org/apache/ignite/internal/processors/query/h2/H2IndexingAbstractGeoSelfTest.java
@@ -562,8 +562,6 @@ public abstract class H2IndexingAbstractGeoSelfTest extends GridCacheAbstractSel
}
checkDistributedQuery();
-
- checkLocalQuery();
}
finally {
destroy(c1, grid(0), dynamic);
@@ -604,43 +602,6 @@ public abstract class H2IndexingAbstractGeoSelfTest extends GridCacheAbstractSel
}
/**
- * Check local query.
- *
- * @throws ParseException If failed.
- */
- private void checkLocalQuery() throws ParseException {
- IgniteCache<Integer, Enemy> c1 = grid(0).cache("enemy");
- IgniteCache<Integer, EnemyCamp> c2 = grid(0).cache("camp");
-
- final Geometry lethalArea = new WKTReader().read("POLYGON((30 30, 30 70, 70 70, 70 30, 30 30))");
-
- Set<Integer> localCampsIDs = new HashSet<>();
-
- for(Cache.Entry<Integer, EnemyCamp> e : c2.localEntries())
- localCampsIDs.add(e.getKey());
-
- int expectedEnemies = 0;
-
- for (Cache.Entry<Integer, Enemy> e : c1.localEntries()) {
- final Integer campID = e.getValue().campId;
-
- if (localCampsIDs.contains(campID)) {
- final EnemyCamp camp = c2.get(campID);
-
- if (lethalArea.covers(camp.coords))
- expectedEnemies++;
- }
- }
-
- final SqlFieldsQuery query = new SqlFieldsQuery("select e._val, c._val from \"enemy\".Enemy e, " +
- "\"camp\".EnemyCamp c where e.campId = c._key and c.coords && ?").setArgs(lethalArea);
-
- List<List<?>> result = c1.query(query.setLocal(true)).getAll();
-
- assertEquals(expectedEnemies, result.size());
- }
-
- /**
*
*/
private static class Enemy {