blob: 37680b0025d778cbee574077a49c10143b1510b7 [file] [log] [blame]
roman300b8782022-08-11 12:49:21 +02001#!/usr/bin/expect -f
2
romane84f7dc2022-10-21 10:25:38 +02003if { [info exists ::env(CURRENT_SOURCE_DIR)] } {
4 source "$env(CURRENT_SOURCE_DIR)/tests/expect/common.exp"
Michal Vasko832a6fa2022-10-24 08:31:17 +02005 set yang_dir "$env(CURRENT_SOURCE_DIR)/examples"
romane84f7dc2022-10-21 10:25:38 +02006} else {
7 source "common.exp"
Michal Vasko832a6fa2022-10-24 08:31:17 +02008 set yang_dir "../../examples"
romane84f7dc2022-10-21 10:25:38 +02009}
roman300b8782022-08-11 12:49:21 +020010
Michal Vasko832a6fa2022-10-24 08:31:17 +020011spawn $yanglint
romane84f7dc2022-10-21 10:25:38 +020012
Michal Vaskob4cf6d12022-11-09 10:26:14 +010013# skip no dir and/or no history warnings
14expect_output "(YANGLINT.*)*> "
romane84f7dc2022-10-21 10:25:38 +020015
16expect_command "feature -a" 1 "yang:\r\n\t\\(none\\)\r\n\r\nietf-yang-schema-mount:\r\n\t\\(none\\)\r\n\r\n> "
17
roman300b8782022-08-11 12:49:21 +020018send -- "exit\r"
romane84f7dc2022-10-21 10:25:38 +020019
roman300b8782022-08-11 12:49:21 +020020expect eof