From 33918c32b8de4250c450f8d0b007019913c440a1 Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Thu, 10 Sep 2020 13:34:46 +0200 Subject: Add is_tty field to Context This patch adds the is_tty field to the Context struct that indicates whether stdout is a TTY. This allows us to use TTY features like moving the cursor in our output. --- src/tests/mod.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'src/tests') diff --git a/src/tests/mod.rs b/src/tests/mod.rs index e0a5b9a..1871f3c 100644 --- a/src/tests/mod.rs +++ b/src/tests/mod.rs @@ -99,6 +99,7 @@ impl Nitrocli { let ctx = &mut crate::Context { stdout: &mut stdout, stderr: &mut stderr, + is_tty: false, admin_pin: self.admin_pin.clone(), user_pin: self.user_pin.clone(), new_admin_pin: self.new_admin_pin.clone(), -- cgit v1.2.3