Beispiel #1
0
 def test_passed_geometry(self, stubs, js_rect):
     """Make sure geometry isn't called when a geometry is passed."""
     frame = stubs.FakeWebFrame(QRect(0, 0, 200, 200))
     raw_elem = get_webelem(frame=frame, js_rect_return=js_rect)._elem
     rect = QRect(10, 20, 30, 40)
     assert webelem.rect_on_view(raw_elem, elem_geometry=rect) == rect
     assert not raw_elem.geometry.called
Beispiel #2
0
 def test_passed_geometry(self, stubs):
     """Make sure geometry isn't called when a geometry is passed."""
     raw_elem = get_webelem()._elem
     rect = QRect(10, 20, 30, 40)
     assert webelem.rect_on_view(raw_elem, rect) == rect
     assert not raw_elem.geometry.called
Beispiel #3
0
 def test_passed_geometry(self, stubs):
     """Make sure geometry isn't called when a geometry is passed."""
     raw_elem = get_webelem()._elem
     rect = QRect(10, 20, 30, 40)
     assert webelem.rect_on_view(raw_elem, rect) == rect
     assert not raw_elem.geometry.called