kopia lustrzana https://github.com/wagtail/wagtail
Removed Rect.get_key
rodzic
214e337aef
commit
610ae217e6
|
@ -57,13 +57,3 @@ class Rect(object):
|
|||
x + width / 2,
|
||||
y + height / 2,
|
||||
)
|
||||
|
||||
|
||||
# DELETEME
|
||||
def get_key(self):
|
||||
return "%(x)d-%(y)d-%(width)dx%(height)d" % {
|
||||
'x': int(self.centroid_x),
|
||||
'y': int(self.centroid_y),
|
||||
'width': int(self.width),
|
||||
'height': int(self.height),
|
||||
}
|
||||
|
|
|
@ -237,7 +237,3 @@ class TestRect(TestCase):
|
|||
def test_from_point(self):
|
||||
rect = Rect.from_point(100, 200, 50, 20)
|
||||
self.assertEqual(rect, Rect(75, 190, 125, 210))
|
||||
|
||||
def test_get_key(self):
|
||||
rect = Rect(100, 150, 200, 250)
|
||||
self.assertEqual(rect.get_key(), '150-200-100x100')
|
||||
|
|
Ładowanie…
Reference in New Issue