public void CanSearchEmpty()
        {
            var spatialIndex = new ExceptionObjectSpatialIndex();

            IPoint point = GeometryFactory.CreatePoint(1000, 1000);

            List <ExceptionObject> exceptionObjects = spatialIndex.Search(point).ToList();

            Assert.AreEqual(0, exceptionObjects.Count);
        }
        private static void AssertCanFindGeometry([NotNull] IGeometry geometry)
        {
            ExceptionObject exceptionObject = CreateExceptionObject(1, geometry);

            var spatialIndex = new ExceptionObjectSpatialIndex();

            spatialIndex.Add(exceptionObject);

            List <ExceptionObject> exceptionObjects = spatialIndex.Search(geometry).ToList();

            Assert.AreEqual(1, exceptionObjects.Count);
        }
        public void CanSearchCoincidentPoints()
        {
            IPoint point = GeometryFactory.CreatePoint(1000, 1000);

            var spatialIndex = new ExceptionObjectSpatialIndex();

            const int count = 100;

            for (int i = 0; i < count; i++)
            {
                spatialIndex.Add(CreateExceptionObject(1, GeometryFactory.Clone(point)));
            }

            List <ExceptionObject> exceptionObjects = spatialIndex.Search(point).ToList();

            Assert.AreEqual(count, exceptionObjects.Count);
        }