Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Joseph Siddons
GeoSpatialTools
Commits
70d3df9c
Commit
70d3df9c
authored
5 months ago
by
Joseph Siddons
Browse files
Options
Download
Email Patches
Plain Diff
test: add test for Rectangle completely containing, or contained within, another
parent
029d7fea
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
test/test_octtree.py
test/test_octtree.py
+10
-0
No files found.
test/test_octtree.py
View file @
70d3df9c
...
...
@@ -72,6 +72,16 @@ class TestRect(unittest.TestCase):
)
assert
not
rect
.
intersects
(
test_rect
)
def
test_inside
(
self
):
# TEST: rectangle fully inside another
d
=
datetime
(
1978
,
5
,
17
,
2
,
33
)
dt
=
timedelta
(
days
=
4
,
hours
=
7
)
outer
=
Rectangle
(
-
10
,
10
,
d
,
-
10
,
10
,
dt
)
inner
=
Rectangle
(
-
5
,
5
,
d
,
-
5
,
5
,
timedelta
(
days
=
1
,
hours
=
3
))
assert
outer
.
intersects
(
inner
)
assert
inner
.
intersects
(
outer
)
class
TestOctTree
(
unittest
.
TestCase
):
def
test_divides
(
self
):
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment