summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/test_colors.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/test_colors.py b/tests/test_colors.py
index bc95f71..0d16bfa 100644
--- a/tests/test_colors.py
+++ b/tests/test_colors.py
@@ -12,6 +12,7 @@ from ansicolor import strip_escapes
from ansicolor import wrap_string
from ansicolor import get_code_v2
from ansicolor import colorize_v2
+from ansicolor import set_term_title
import ansicolor
@@ -179,3 +180,10 @@ def test_justify_formatted():
assert justify_formatted(
red("hi"), rjust, 10
) == " " + red("hi")
+
+
+def test_set_term_title(capsys):
+ set_term_title('ansicolor demo')
+
+ captured = capsys.readouterr()
+ assert '\033]2;ansicolor demo\007' == captured.out \ No newline at end of file