blob: c1b384f821235246f487fc873a54e40c286b1e14 [file] [log] [blame]
aPiecek07bc9632023-06-01 12:14:48 +02001source [expr {[info exists ::env(TESTS_DIR)] ? "$env(TESTS_DIR)/interactive/ly.tcl" : "ly.tcl"}]
2
3set mdir $::env(YANG_MODULES_DIR)
4
5variable ly_setup {
6 spawn $::env(YANGLINT)
7 ly_skip_warnings
8}
9
10test searchpath_basic {} {
11-setup $ly_setup -cleanup $ly_cleanup -body {
12 ly_cmd "searchpath $mdir"
13 ly_cmd "searchpath" "$mdir"
14 ly_cmd "load modleaf"
15}}
16
17test searchpath_clear {searchpath --clear} {
18-setup $ly_setup -cleanup $ly_cleanup -body {
19 ly_cmd "searchpath $mdir"
20 ly_cmd "searchpath --clear"
21 ly_cmd_err "load modleaf" "Data model \"modleaf\" not found in local searchdirs"
22}}
23
24cleanupTests