Delete buttons when we are finished so they do not overlap later controls and cause test failures.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70872 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -145,7 +145,7 @@ void MiscGUIFuncsTestCase::FindWindowAtPoint()
|
|||||||
!wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(900, 900)))
|
!wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(900, 900)))
|
||||||
);
|
);
|
||||||
|
|
||||||
wxWindow* const btn1 = new wxButton(parent, wxID_ANY, "1", wxPoint(10, 10));
|
wxWindow* btn1 = new wxButton(parent, wxID_ANY, "1", wxPoint(10, 10));
|
||||||
CPPUNIT_ASSERT_EQUAL_MESSAGE
|
CPPUNIT_ASSERT_EQUAL_MESSAGE
|
||||||
(
|
(
|
||||||
"Point over a child control corresponds to it",
|
"Point over a child control corresponds to it",
|
||||||
@@ -160,7 +160,7 @@ void MiscGUIFuncsTestCase::FindWindowAtPoint()
|
|||||||
wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(5, 5)))
|
wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(5, 5)))
|
||||||
);
|
);
|
||||||
|
|
||||||
wxWindow* const btn2 = new wxButton(parent, wxID_ANY, "2", wxPoint(10, 90));
|
wxWindow* btn2 = new wxButton(parent, wxID_ANY, "2", wxPoint(10, 90));
|
||||||
btn2->Disable();
|
btn2->Disable();
|
||||||
CPPUNIT_ASSERT_EQUAL_MESSAGE
|
CPPUNIT_ASSERT_EQUAL_MESSAGE
|
||||||
(
|
(
|
||||||
@@ -176,4 +176,7 @@ void MiscGUIFuncsTestCase::FindWindowAtPoint()
|
|||||||
parent,
|
parent,
|
||||||
wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(11, 91)))
|
wxFindWindowAtPoint(parent->ClientToScreen(wxPoint(11, 91)))
|
||||||
);
|
);
|
||||||
|
|
||||||
|
wxDELETE(btn1);
|
||||||
|
wxDELETE(btn2);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user