File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -481,10 +481,12 @@ class WindowIndexTest(TmuxTestCase):
481
481
"""
482
482
483
483
def test_window_index (self ):
484
+ proc = self .session .tmux ('show-option' , '-gv' , 'base-index' )
485
+ base_index = int (proc .stdout [0 ])
484
486
name_index_map = {
485
- 'zero' : '0' ,
486
- 'one' : '1' ,
487
- 'five' : '5' ,
487
+ 'zero' : 0 + base_index ,
488
+ 'one' : 1 + base_index ,
489
+ 'five' : 5 ,
488
490
}
489
491
490
492
sconfig = kaptan .Kaptan (handler = 'yaml' )
@@ -494,7 +496,6 @@ def test_window_index(self):
494
496
495
497
builder = WorkspaceBuilder (sconf = sconfig )
496
498
497
-
498
499
for window , wconf in builder .iter_create_windows (self .session ):
499
500
expected_index = name_index_map [window ['window_name' ]]
500
- self .assertEqual (window ['window_index' ], expected_index )
501
+ self .assertEqual (int ( window ['window_index' ]) , expected_index )
You can’t perform that action at this time.
0 commit comments