Commit 3428ea0
schema: return float for decimal64 in default function
This patch changes the output for leaf/leaf-list nodes using decimal64
type, and adds new unit test for this purpose.
The leaf-list defaults function is reworked to be similar to the leaf
default function. A new yang schema is added for clarity, and to avoid
modifying all the tests using yolo-system.yang.
Fixes: #80
Signed-off-by: Stefan Gula <steweg@gmail.com>
Signed-off-by: Samuel Gauthier <samuel.gauthier@6wind.com>1 parent 3b4d509 commit 3428ea0
File tree
3 files changed
+74
-6
lines changed- libyang
- tests
- yang/yolo
3 files changed
+74
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1209 | 1209 | | |
1210 | 1210 | | |
1211 | 1211 | | |
1212 | | - | |
| 1212 | + | |
1213 | 1213 | | |
1214 | 1214 | | |
1215 | 1215 | | |
| |||
1221 | 1221 | | |
1222 | 1222 | | |
1223 | 1223 | | |
| 1224 | + | |
| 1225 | + | |
1224 | 1226 | | |
1225 | 1227 | | |
1226 | 1228 | | |
| |||
1268 | 1270 | | |
1269 | 1271 | | |
1270 | 1272 | | |
1271 | | - | |
| 1273 | + | |
1272 | 1274 | | |
1273 | 1275 | | |
1274 | 1276 | | |
| |||
1278 | 1280 | | |
1279 | 1281 | | |
1280 | 1282 | | |
1281 | | - | |
| 1283 | + | |
1282 | 1284 | | |
1283 | 1285 | | |
1284 | | - | |
| 1286 | + | |
1285 | 1287 | | |
1286 | | - | |
1287 | | - | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
1288 | 1293 | | |
1289 | 1294 | | |
1290 | 1295 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
474 | 474 | | |
475 | 475 | | |
476 | 476 | | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
0 commit comments