Skip to content

Commit 135e923

Browse files
committed
try to fix test with new rich
1 parent ba1281a commit 135e923

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/func/utils/test_strict_yaml.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -323,12 +323,16 @@ def force_posixpath(mocker):
323323

324324

325325
@pytest.fixture
326-
def fixed_width_term(mocker):
326+
def fixed_width_term(mocker, monkeypatch):
327327
"""Fixed width console."""
328328
from rich.console import Console
329329

330+
from dvc.ui import ui
331+
332+
width = 80 + ui.rich_console.legacy_windows
333+
330334
mocker.patch.object(
331-
Console, "width", new_callable=mocker.PropertyMock(return_value=80)
335+
Console, "width", new_callable=mocker.PropertyMock(return_value=width)
332336
)
333337

334338

0 commit comments

Comments
 (0)