mirror of
https://github.com/frappe/gunicorn.git
synced 2026-01-14 11:09:11 +08:00
test error message in test_invalid_enviroment_variables_config test.
This commit is contained in:
parent
79a9697df2
commit
e007601f0d
@ -302,12 +302,13 @@ def test_load_enviroment_variables_config(monkeypatch):
|
||||
assert app.cfg.workers == 4
|
||||
|
||||
|
||||
def test_invalid_enviroment_variables_config(monkeypatch):
|
||||
def test_invalid_enviroment_variables_config(monkeypatch, capsys):
|
||||
monkeypatch.setenv("GUNICORN_CMD_ARGS", "--foo=bar")
|
||||
with AltArgs():
|
||||
with pytest.raises(SystemExit):
|
||||
NoConfigApp()
|
||||
|
||||
_, err = capsys.readouterr()
|
||||
assert "error: unrecognized arguments: --foo" in err
|
||||
|
||||
def test_cli_overrides_enviroment_variables_module(monkeypatch):
|
||||
monkeypatch.setenv("GUNICORN_CMD_ARGS", "--workers=4")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user