Remove gtkmozembed view widget from the frame - workaround for shutdown issues with...
[straw.git] / test / test_items.py
blob717aeb314377f101ecb10674acf4647b11d2b60c
2 import pygtk
3 import gobject
4 from mock import Mock
5 import nose
7 from straw.SummaryItem import SummaryItem
9 class TestSummaryItem:
10 def setUp(self):
11 mock = Mock( {
12 'add_refer': None,
13 '__nonzero__' : 1
15 self.summaryItem = SummaryItem(mock)
17 def tearDown(self):
18 self.summaryItem = None
19 mock = None
21 def test_seen(self):
22 def _cb(*args): assert True
23 self.summaryItem.connect('read', _cb)
24 self.summaryItem.seen = True
25 assert self.summaryItem.seen is True
27 def test_sticky(self):
28 def _cb(*args): assert True
29 self.summaryItem.connect('sticky', _cb)
30 self.summaryItem.sticky = True
31 assert self.summaryItem.sticky is True
32 self.summaryItem.sticky = False
33 assert self.summaryItem.sticky is False
35 def test_id(self):
36 self.summaryItem.id = 1
37 assert summaryItem.id is 1