mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-04 08:24:40 +01:00
Updated prompt test to handle new behavior
This commit is contained in:
parent
6fbe2795d3
commit
9c3a28e011
1 changed files with 1 additions and 1 deletions
|
@ -94,7 +94,7 @@ def test_format_prompt_with_invalid_func(formatter, xonsh_builtins):
|
|||
def test_format_prompt_with_func_that_raises(formatter, capsys, xonsh_builtins):
|
||||
xonsh_builtins.__xonsh__.env = Env()
|
||||
template = "tt {zerodiv} tt"
|
||||
exp = "tt (ERROR:zerodiv) tt"
|
||||
exp = "tt {BACKGROUND_RED}{ERROR:zerodiv}{NO_COLOR} tt"
|
||||
fields = {"zerodiv": lambda: 1 / 0}
|
||||
obs = formatter(template, fields)
|
||||
assert exp == obs
|
||||
|
|
Loading…
Add table
Reference in a new issue