test em
This commit is contained in:
parent
daf81343bf
commit
a2b33b25f8
11 changed files with 479 additions and 55 deletions
14
tests/test_console.py
Normal file
14
tests/test_console.py
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
from learn_sql_model.console import console
|
||||
|
||||
|
||||
def test_default_console_not_quiet(capsys):
|
||||
console.print("hello")
|
||||
captured = capsys.readouterr()
|
||||
assert captured.out == "hello\n"
|
||||
|
||||
|
||||
def test_default_console_is_quiet(capsys):
|
||||
console.quiet = True
|
||||
console.print("hello")
|
||||
captured = capsys.readouterr()
|
||||
assert captured.out == ""
|
||||
Loading…
Add table
Add a link
Reference in a new issue