Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions tests/yanglint/interactive/all.tcl
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
package require tcltest
package require Expect

# Save current terminal size
set stty_output [exec stty size]
scan $stty_output "%d %d" orig_lines orig_columns
# setting some large terminal width
stty columns 720

# Hook to determine if any of the tests failed.
# Sets a global variable exitCode to 1 if any test fails otherwise it is set to 0.
Expand All @@ -11,5 +18,10 @@ if {[info exists ::env(TESTS_DIR)]} {
tcltest::configure -testdir "$env(TESTS_DIR)/interactive"
}

# run all interactive tests
tcltest::runAllTests

# Restore original terminal size
exec stty rows $orig_lines cols $orig_columns

exit $exitCode
2 changes: 0 additions & 2 deletions tests/yanglint/interactive/ly.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ set timeout 5
set prompt "> "
# turn off dialog between expect and yanglint
log_user 0
# setting some large terminal width
stty columns 720

# default setup for every unit test
variable ly_setup {
Expand Down