Bug 5830: Mandatory leaf enforcement is not correct with presence container
[yangtools.git] / yang / yang-data-impl / src / test / resources / bug5830 / foo-non-presence.yang
1 module foo-non-presence {
2     yang-version 1;
3     namespace "foo";
4     prefix foo;
5
6     revision 2016-05-17 {
7         description "test";
8     }
9
10     container task-container {
11         list task {
12             key "task-id";
13
14             leaf task-id {
15                 type string;
16             }
17             leaf task-mandatory-leaf {
18                 type string;
19                 mandatory true;
20             }
21
22             container task-data {
23                 leaf mandatory-data {
24                     type string;
25                     mandatory true;
26                 }
27                 leaf other-data {
28                     type string;
29                 }
30             }
31         }
32     }
33 }