summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMaxime “pep” Buquet <pep@bouah.net>2018-09-10 22:45:23 +0100
committerMaxime “pep” Buquet <pep@bouah.net>2018-09-10 22:45:23 +0100
commit65649e91c4f2130143645a6901bfb029e44e2993 (patch)
treecbf5b05e0b4b026ff56b5c78092dc396f960d5f8 /test
parentbb9bc80d9b41acef30338943e5d27182fa0e75e6 (diff)
downloadpoezio-65649e91c4f2130143645a6901bfb029e44e2993.tar.gz
poezio-65649e91c4f2130143645a6901bfb029e44e2993.tar.bz2
poezio-65649e91c4f2130143645a6901bfb029e44e2993.tar.xz
poezio-65649e91c4f2130143645a6901bfb029e44e2993.zip
Tabs: add test for slice support
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
Diffstat (limited to 'test')
-rw-r--r--test/test_tabs.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/test_tabs.py b/test/test_tabs.py
index aab4f0d0..0a6930d4 100644
--- a/test/test_tabs.py
+++ b/test/test_tabs.py
@@ -172,3 +172,14 @@ def test_set_current():
tabs.set_current_tab(dummy2)
assert tabs.current_tab is dummy2
+def test_slice():
+ DummyTab.reset()
+ tabs = Tabs(h)
+ dummy = DummyTab()
+ dummy2 = DummyTab()
+ dummy3 = DummyTab()
+ tabs.append(dummy)
+ tabs.append(dummy2)
+ tabs.append(dummy3)
+
+ assert tabs[1:2][0] is dummy2