* Added stricter check on schema-node identifier checking, such as for augments.

* These checks are now made at YANG loading time
This commit is contained in:
Olof hagsand 2020-09-29 20:53:24 +02:00
parent 101a8cb6e0
commit b3545871c0
8 changed files with 383 additions and 202 deletions

View file

@ -38,6 +38,9 @@ cat <<EOF > $ydir/moda.yang
module moda{
namespace "urn:example:a";
prefix a;
import modb{
prefix b;
}
container x1{
description "list with single string key";
list y{
@ -150,6 +153,7 @@ done
echo -n '</x1>' >> $xml1
new "api-path single string key k1=a$rnd"
echo "$clixon_util_path -f $xml1 -y $ydir -p /moda:x1/y=a$rnd"
expectpart "$($clixon_util_path -f $xml1 -y $ydir -p /moda:x1/y=a$rnd)" 0 "^0: <y><k1>a$rnd</k1><z>foo$rnd</z></y>$"
new "api-path single string key /x1"

View file

@ -60,7 +60,7 @@ module B{
import A {
prefix "a";
}
augment "/a:x/ngrt:y" {
augment "/a:x/a:y" {
container z {
leaf w {
type string;

View file

@ -30,6 +30,9 @@ cat <<EOF > $ydir/moda.yang
module moda{
namespace "urn:example:a";
prefix a;
import modb {
prefix b;
}
container x1{
description "list with single string key";
list y{

View file

@ -34,6 +34,7 @@ fi
cat <<EOF > $cfg
<clixon-config xmlns="http://clicon.org/config">
<CLICON_CONFIGFILE>$cfg</CLICON_CONFIGFILE>
<CLICON_FEATURE>ni-ieee1588-ptp:cmlds</CLICON_FEATURE>
<CLICON_YANG_DIR>$YANGMODELS/standard/ietf/RFC</CLICON_YANG_DIR>
<CLICON_YANG_DIR>$YANGMODELS/standard/ieee/draft/802.1/Qcr</CLICON_YANG_DIR>
<CLICON_YANG_DIR>$YANGMODELS/standard/ieee/draft/802</CLICON_YANG_DIR>