Exemple #1
0
 def test_bottom_left(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_LEFT)
     assert geometry.rotation == "45"
Exemple #2
0
 def test_bottom_right(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_RIGHT)
     assert geometry.rotation == "-45"
Exemple #3
0
 def test_top_left(self):
     geometry = Geometry(IMAGE_SIZE, TOP_LEFT)
     assert geometry.rotation == "-45"
Exemple #4
0
 def test_top_right(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.rotation == "45"
Exemple #5
0
 def test_bottom_left(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_LEFT)
     assert geometry.gravity == "SouthWest"
Exemple #6
0
 def test_bottom_right(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_RIGHT)
     assert geometry.gravity == "SouthEast"
Exemple #7
0
 def test_top_left(self):
     geometry = Geometry(IMAGE_SIZE, TOP_LEFT)
     assert geometry.gravity == "NorthWest"
Exemple #8
0
 def test_it_has_correct_value(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.thickness == 25.0
Exemple #9
0
 def test_bottom_left(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_LEFT)
     assert geometry.path == "M 0,37.5 62.5,100 37.5,100 0,62.5 Z"
Exemple #10
0
 def test_bottom_right(self):
     geometry = Geometry(IMAGE_SIZE, BOTTOM_RIGHT)
     assert geometry.path == "M 37.5,100 100,37.5 100,62.5 62.5,100 Z"
Exemple #11
0
 def test_top_right(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.path == "M 37.5,0 62.5,0 100,37.5 100,62.5 Z"
Exemple #12
0
 def test_top_left(self):
     geometry = Geometry(IMAGE_SIZE, TOP_LEFT)
     assert geometry.path == "M 0,62.5 0,37.5 37.5,0 62.5,0 Z"
Exemple #13
0
 def test_it_has_correct_vertical_and_horizontal_values(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.size == "62.5x62.5"
Exemple #14
0
 def test_it_has_correct_value(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.pointsize == "12.5"
Exemple #15
0
 def test_top_right(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.gravity == "NorthEast"
Exemple #16
0
 def test_it_has_correct_value(self):
     geometry = Geometry(IMAGE_SIZE, TOP_RIGHT)
     assert geometry.translation == "+6.25+6.25"
Exemple #17
0
 def test_invalid_position(self):
     try:
         Geometry(IMAGE_SIZE, "INVALID")
         assert False
     except InvalidEmbroideryPosition:
         pass