File tree Expand file tree Collapse file tree 1 file changed +16
-15
lines changed Expand file tree Collapse file tree 1 file changed +16
-15
lines changed Original file line number Diff line number Diff line change 4
4
5
5
import pytest
6
6
7
- from libtmux .common import has_lt_version
7
+ from libtmux .common import has_gte_version , has_lt_version
8
8
from libtmux .constants import ResizeAdjustmentDirection
9
9
from libtmux .session import Session
10
10
@@ -173,20 +173,21 @@ def test_resize_pane(
173
173
)
174
174
assert int (pane .pane_width ) == 75
175
175
176
- # Manual: Height percentage
177
- window .select_layout ("main-vertical" )
178
- pane_height_before = int (pane .pane_height )
179
- pane .resize_pane (
180
- height = "15%" ,
181
- )
182
- assert int (pane .pane_height ) == 75
183
-
184
- # Manual: Width percentage
185
- window .select_layout ("main-horizontal" )
186
- pane .resize_pane (
187
- width = "15%" ,
188
- )
189
- assert int (pane .pane_width ) == 75
176
+ if has_gte_version ("3.0" ):
177
+ # Manual: Height percentage
178
+ window .select_layout ("main-vertical" )
179
+ pane_height_before = int (pane .pane_height )
180
+ pane .resize_pane (
181
+ height = "15%" ,
182
+ )
183
+ assert int (pane .pane_height ) == 75
184
+
185
+ # Manual: Width percentage
186
+ window .select_layout ("main-horizontal" )
187
+ pane .resize_pane (
188
+ width = "15%" ,
189
+ )
190
+ assert int (pane .pane_width ) == 75
190
191
191
192
#
192
193
# Adjustments
You can’t perform that action at this time.
0 commit comments