@@ -323,18 +323,14 @@ def force_posixpath(mocker):
323
323
324
324
325
325
@pytest .fixture
326
- def fixed_width_term ( mocker ):
326
+ def dumb_terminal ( monkeypatch ):
327
327
"""Fixed width console."""
328
- from rich .console import Console
329
-
330
- mocker .patch .object (
331
- Console , "width" , new_callable = mocker .PropertyMock (return_value = 80 )
332
- )
328
+ monkeypatch .setenv ("TERM" , "dumb" )
333
329
334
330
335
331
@pytest .mark .parametrize ("text, expected" , examples .values (), ids = examples .keys ())
336
332
def test_exceptions (
337
- tmp_dir , dvc , capsys , force_posixpath , fixed_width_term , text , expected
333
+ tmp_dir , dvc , capsys , force_posixpath , dumb_terminal , text , expected
338
334
):
339
335
tmp_dir .gen ("dvc.yaml" , text )
340
336
@@ -358,7 +354,7 @@ def test_exceptions(
358
354
],
359
355
)
360
356
def test_on_revision (
361
- tmp_dir , scm , dvc , force_posixpath , fixed_width_term , capsys , text , expected
357
+ tmp_dir , scm , dvc , force_posixpath , dumb_terminal , capsys , text , expected
362
358
):
363
359
tmp_dir .scm_gen ("dvc.yaml" , text , commit = "add dvc.yaml" )
364
360
capsys .readouterr () # clear outputs
0 commit comments