summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHamilton Kibbe <hamilton.kibbe@gmail.com>2016-11-18 08:14:26 -0500
committerHamilton Kibbe <hamilton.kibbe@gmail.com>2016-11-18 08:14:26 -0500
commite07ccc805fbaf05cff35e423d1559279bb2bc15e (patch)
tree1b17012f24da0c2264a503cf49d41cc552a80269
parent389c273a8787a20f3e6ea5fdb951f62d7d5d4999 (diff)
downloadgerbonara-e07ccc805fbaf05cff35e423d1559279bb2bc15e.tar.gz
gerbonara-e07ccc805fbaf05cff35e423d1559279bb2bc15e.tar.bz2
gerbonara-e07ccc805fbaf05cff35e423d1559279bb2bc15e.zip
Fix drill tests
-rw-r--r--gerber/tests/test_primitives.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/gerber/tests/test_primitives.py b/gerber/tests/test_primitives.py
index 97b335b..2fe5a4b 100644
--- a/gerber/tests/test_primitives.py
+++ b/gerber/tests/test_primitives.py
@@ -1270,7 +1270,7 @@ def test_drill_ctor():
"""
test_cases = (((0, 0), 2), ((1, 1), 3), ((2, 2), 5))
for position, diameter in test_cases:
- d = Drill(position, diameter, None)
+ d = Drill(position, diameter)
assert_equal(d.position, position)
assert_equal(d.diameter, diameter)
assert_equal(d.radius, diameter / 2.)
@@ -1279,24 +1279,24 @@ def test_drill_ctor():
def test_drill_ctor_validation():
""" Test drill argument validation
"""
- assert_raises(TypeError, Drill, 3, 5, None)
- assert_raises(TypeError, Drill, (3,4,5), 5, None)
+ assert_raises(TypeError, Drill, 3, 5)
+ assert_raises(TypeError, Drill, (3,4,5), 5)
def test_drill_bounds():
- d = Drill((0, 0), 2, None)
+ d = Drill((0, 0), 2)
xbounds, ybounds = d.bounding_box
assert_array_almost_equal(xbounds, (-1, 1))
assert_array_almost_equal(ybounds, (-1, 1))
- d = Drill((1, 2), 2, None)
+ d = Drill((1, 2), 2)
xbounds, ybounds = d.bounding_box
assert_array_almost_equal(xbounds, (0, 2))
assert_array_almost_equal(ybounds, (1, 3))
def test_drill_conversion():
- d = Drill((2.54, 25.4), 254., None, units='metric')
+ d = Drill((2.54, 25.4), 254., units='metric')
#No effect
d.to_metric()