diff options
author | hut <hut@lavabit.com> | 2009-12-31 03:40:08 +0100 |
---|---|---|
committer | hut <hut@lavabit.com> | 2009-12-31 03:40:08 +0100 |
commit | a6791aeef4c62960563882796d993873febe7b9c (patch) | |
tree | 33f5d9f01607b0795641960436c03160cc232201 /test | |
parent | cd603ff4d0573c407c82f40cba9a164f7373585d (diff) | |
download | ranger-a6791aeef4c62960563882796d993873febe7b9c.tar.gz |
added documentation, clean up
Diffstat (limited to 'test')
-rw-r--r-- | test/tc_displayable.py | 12 | ||||
-rw-r--r-- | test/tc_ui.py | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/test/tc_displayable.py b/test/tc_displayable.py index 3acf338b..d7466809 100644 --- a/test/tc_displayable.py +++ b/test/tc_displayable.py @@ -74,7 +74,7 @@ class TestDisplayableContainer(unittest.TestCase): self.disp = Displayable(**self.initdict) self.disc = DisplayableContainer(**self.initdict) - self.disc.add_obj(self.disp) + self.disc.add_child(self.disp) hei, wid = (100, 100) self.env.termsize = (hei, wid) @@ -103,20 +103,20 @@ class TestDisplayableContainer(unittest.TestCase): def test_focused_object(self): d1 = Displayable(**self.initdict) d2 = DisplayableContainer(**self.initdict) - d2.add_obj(*[Displayable(**self.initdict) for x in range(5)]) + d2.add_child(*[Displayable(**self.initdict) for x in range(5)]) d3 = DisplayableContainer(**self.initdict) - d3.add_obj(*[Displayable(**self.initdict) for x in range(5)]) + d3.add_child(*[Displayable(**self.initdict) for x in range(5)]) - self.disc.add_obj(d1, d2, d3) + self.disc.add_child(d1, d2, d3) d3.container[3].focused = True - self.assertEqual(self.disc.get_focused_obj(), d3.container[3]) + self.assertEqual(self.disc._get_focused_obj(), d3.container[3]) d3.container[3].focused = False d2.container[0].focused = True - self.assertEqual(self.disc.get_focused_obj(), d2.container[0]) + self.assertEqual(self.disc._get_focused_obj(), d2.container[0]) if __name__ == '__main__': unittest.main() diff --git a/test/tc_ui.py b/test/tc_ui.py index f509ff36..eb503c5d 100644 --- a/test/tc_ui.py +++ b/test/tc_ui.py @@ -17,7 +17,7 @@ class Test(unittest.TestCase): def fakesetup(): self.ui.widget = Fake() - self.ui.add_obj(self.ui.widget) + self.ui.add_child(self.ui.widget) self.ui.setup = fakesetup self.ui.initialize() |