Bug 2363, Bug 2205. Beta version of LeafRefContext tree computation
[yangtools.git] / yang / yang-data-impl / src / test / resources / leafref-context-test / incorrect-modules / leafref-test.yang
1 module leafref-test {
2     namespace "test";
3     prefix test;
4
5     container odl-contributor {
6         list contributor {
7             key "login";
8             leaf login {
9                 type string;
10             }
11             leaf contributor-name {
12                 type string;
13             }
14             leaf odl-project-name {
15                 type leafref {
16                     path ".../odl-project/project/name";
17                 }
18             }
19         }
20         list noleafref-contributor {
21             leaf foo {
22                 type string;
23             }
24         }
25     }
26
27     container odl-project {
28         list project {
29             key "name";
30             leaf name {
31                 type string;
32             }
33             leaf project-lead {
34                 type leafref {
35                     path "/odl-contributor/contributor/login";
36                 }
37             }
38         }
39         list noleafref-project {
40             leaf foo {
41                 type string;
42             }
43         }
44     }
45
46     container con1 {
47         container con2 {
48             container con3 {
49                 leaf l1 {
50                     type leafref {
51                         path "/odl-project/project/name";
52                     }
53                 }
54                 leaf l2 {
55                     type leafref {
56                         path "/odl-project/project/name";
57                     }
58                 }
59                 leaf l3-noleafref {
60                     type int16;
61                 }
62             }
63             leaf l4 {
64                 type leafref {
65                     path "/odl-project/project/name";
66                 }
67             }
68             leaf l5-noleafref {
69                 type int16;
70             }
71         }
72         leaf l6 {
73             type leafref {
74                 path "/odl-project/project/name";
75             }
76         }
77         leaf l7-noleafref {
78             type int16;
79         }
80     }
81
82     leaf l8 {
83         type leafref {
84             path "/odl-project/project/name";
85         }
86     }
87
88     container no-leafrefcontainer {
89         list no-leafreflist {
90             leaf bar {
91                 type string;
92             }
93         }
94         container no-leafrefcontainer2 {
95             leaf baz {
96                 type string;
97             }
98         }
99     }
100
101     container no-leafrefcontainer2 {
102         list no-leafreflist {
103             leaf bar {
104                 type string;
105             }
106         }
107         container no-leafrefcontainer2 {
108             leaf baz {
109                 type string;
110             }
111         }
112     }
113
114 }