1import unittest 2from unittests import wtc 3import wx.ribbon 4 5#--------------------------------------------------------------------------- 6 7class ribbon_panel_Tests(wtc.WidgetTestCase): 8 9 def test_ribbon_panel1(self): 10 wx.ribbon.RIBBON_PANEL_NO_AUTO_MINIMISE, 11 wx.ribbon.RIBBON_PANEL_EXT_BUTTON, 12 wx.ribbon.RIBBON_PANEL_MINIMISE_BUTTON, 13 wx.ribbon.RIBBON_PANEL_STRETCH, 14 wx.ribbon.RIBBON_PANEL_FLEXIBLE, 15 wx.ribbon.RIBBON_PANEL_DEFAULT_STYLE 16 17 wx.ribbon.wxEVT_RIBBONPANEL_EXTBUTTON_ACTIVATED 18 wx.ribbon.EVT_RIBBONPANEL_EXTBUTTON_ACTIVATED 19 20 21 def test_ribbon_panel2(self): 22 evt = wx.ribbon.RibbonPanelEvent() 23 self.assertTrue(evt.Panel is None) 24 25 26 def test_ribbon_panel3(self): 27 bar = wx.ribbon.RibbonBar(self.frame) 28 p = wx.ribbon.RibbonPanel() 29 p.Create(bar) 30 31 32 def test_ribbon_panel4(self): 33 bar = wx.ribbon.RibbonBar(self.frame) 34 p = wx.ribbon.RibbonPanel(bar) 35 36 p.GetMinimisedIcon() 37 p.HasExtButton() 38 p.IsMinimised() 39 p.IsHovered() 40 p.CanAutoMinimise() 41 p.ShowExpanded() 42 p.HideExpanded() 43 44 p.ExpandedDummy 45 p.ExpandedPanel 46 47 48 49#--------------------------------------------------------------------------- 50 51if __name__ == '__main__': 52 unittest.main() 53