* Support for YANG conditionals "must" and "when" according to RFC 7950 Sec 7.5.3 and 7.21.5

* XPATH checked at validation time
This commit is contained in:
Olof hagsand 2018-07-18 09:51:33 +02:00
parent ba7f84afee
commit 0eb9e6c8b2
14 changed files with 244 additions and 54 deletions

View file

@ -136,7 +136,7 @@ expecteof "$clixon_netconf -qf $cfg -y $fyang" 0 "<rpc><edit-config><target><can
new "netconf get leaf-list"
expecteof "$clixon_netconf -qf $cfg -y $fyang" 0 "<rpc><get-config><source><candidate/></source><filter type=\"xpath\" select=\"/x/f/e\"/></get-config></rpc>]]>]]>" "^<rpc-reply><data><x><f><e>hej</e><e>hopp</e></f></x></data></rpc-reply>]]>]]>$"
if [ -n "$XPATH_USE_NEW" ]; then # new
if [ -z "$COMPAT_XSL" ]; then # new
new "netconf get leaf-list path"
expecteof "$clixon_netconf -qf $cfg -y $fyang" 0 "<rpc><get-config><source><candidate/></source><filter type=\"xpath\" select=\"/x/f[e='hej']\"/></get-config></rpc>]]>]]>" "^<rpc-reply><data><x><f><e>hej</e><e>hopp</e></f></x></data></rpc-reply>]]>]]>$"
else # old