-
Notifications
You must be signed in to change notification settings - Fork 349
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #886 - crash on deviation of config
- Loading branch information
Showing
4 changed files
with
96 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
test: | ||
$(PYANG) --print-error-code \ | ||
--deviation-module deviation-problem-dev.yang \ | ||
deviation-problem.yang 2>&1 | grep KEY_BAD_CONFIG > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
module deviation-problem-dev { | ||
|
||
yang-version 1.1; | ||
namespace "urn:deviation-problem-dev:1.0"; | ||
prefix "dp-dev"; | ||
|
||
import deviation-problem { | ||
prefix "dp"; | ||
} | ||
|
||
organization "x"; | ||
contact "x"; | ||
description "x"; | ||
revision "2023-12-12" { | ||
description | ||
"version 1.0.0 | ||
1) initial version"; | ||
reference | ||
"x"; | ||
} | ||
|
||
/* Deviations to permit configuration of RO parameters */ | ||
deviation "/dp:top/dp:cnode" { | ||
deviate replace { | ||
config true; | ||
} | ||
} | ||
|
||
/* Deviations to permit configuration of RO parameters */ | ||
deviation "/dp:top/dp:lnode" { | ||
deviate replace { | ||
config true; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
module deviation-problem { | ||
|
||
yang-version 1.1; | ||
namespace "urn:deviation-problem:1.0"; | ||
prefix "deviation-problem"; | ||
|
||
organization "x"; | ||
contact "x"; | ||
description "x"; | ||
revision "2023-12-12" { | ||
description | ||
"version 1.0.0 | ||
1) initial version"; | ||
reference | ||
"x"; | ||
} | ||
|
||
container top { | ||
description "top container"; | ||
|
||
leaf tleaf { | ||
type uint32; | ||
units nanoseconds; | ||
description "eleaf"; | ||
} | ||
|
||
container cnode { | ||
config false; | ||
description "container node"; | ||
leaf cleaf { | ||
type uint32; | ||
units nanoseconds; | ||
description "eleaf"; | ||
} | ||
} | ||
|
||
list lnode { | ||
key "id"; | ||
config false; | ||
description | ||
"List node"; | ||
|
||
leaf id { | ||
type uint16; | ||
description | ||
"list key"; | ||
} | ||
} | ||
} | ||
|
||
} |