Bug 8084 - FilterContentValidator.getKeyValues creates invalid YII key values
[netconf.git] / netconf / mdsal-netconf-connector / src / test / resources / yang / mdsal-netconf-mapping-test.yang
1 module config {
2     yang-version 1;
3     namespace "urn:opendaylight:mdsal:mapping:test";
4     prefix "map";
5
6     revision "2015-02-26";
7
8     identity foo {
9             description "dummy identity";
10     }
11     container mapping-nodes {
12
13         list multiple-keys {
14             key "key3 key1 key2";
15
16             leaf value1 {
17                 type string;
18             }
19
20             leaf key1 {
21                 type string;
22             }
23
24             leaf value2 {
25                 type string;
26             }
27
28             leaf key2 {
29                 type string;
30             }
31
32             leaf key3 {
33                 type string;
34             }
35         }
36         
37         list mapping-node{
38             key "id";
39             leaf id {
40                 type string;
41             }
42
43             leaf content {
44                 type string;
45             }
46         }
47     }
48
49     container top {
50
51         container users {
52
53             list user {
54
55                 key "name";
56
57                 leaf name {
58                     type string;
59                 }
60
61                 leaf type {
62                     type string;
63                 }
64
65                 leaf full-name {
66                     type string;
67                 }
68
69                 container company-info {
70
71                     leaf dept {
72                         type string;
73                     }
74
75                     leaf id {
76                         type string;
77                     }
78                 }
79             }
80         }
81
82         container modules {
83
84             list module {
85
86                 key "id";
87
88                 leaf id {
89                     type string;
90                 }
91
92                 leaf type {
93                     type string;
94                 }
95
96                 leaf desc {
97                     type string;
98                 }
99             }
100         }
101
102         choice choice-node {
103             case a {
104                 leaf text {
105                     type string;
106                 }
107             }
108
109             case b {
110                 container text-cont {
111                     leaf text {
112                         type string;
113                     }
114                 }
115             }
116         }
117
118     } //top
119
120     augment "/map:top/map:choice-node" {
121         case c {
122             leaf augmented-case {
123                 type string;
124             }
125         }
126
127         case d {
128             container choice-wrapper {
129                 choice inner-choice {
130                     case ia {
131                         leaf text {
132                             type string;
133                         }
134                     }
135
136                     case ib {
137                         leaf text2 {
138                             type string;
139                         }
140                     }
141                 }
142             }
143         }
144     }
145
146     augment "/map:top/map:modules/" {
147         container augmented-container{
148             leaf identifier {
149                 type string;
150             }
151         }
152     }
153
154     augment "/map:top" {
155         container mid-level {
156             container low-level {
157                 container lowest-level {
158                     leaf-list note {
159                         type string;
160                     }
161                 }
162             }
163             container low-level2 {
164                 leaf-list note {
165                     type string;
166                 }
167             }
168         }
169     }
170 }