Commit 0220c95
authored
Migrate all tests to using world-file-syntax (#432)
* Update all codegen tests to world syntax
This enables simplifying codegen tests as well by having each test
exercise imports/exports instead of having all code generators have one
case for imports and one for exports.
* Update codegen tests for the C guest generator
* Update teavm codegen tests for worlds
* Remove the `--name` argument from the CLI
No longer needed as the name is inferred from the `*.wit` world.
* Get all js host generator tests working
Update all `runtime/*` tests with new naming conventions, world files,
etc. Minor updates were made to names as I ended up using different
conventions for the `*.wit` world files than were previously exercised.
This also fixes a few minor issues with the output for the JS generator
in the default ESM mode.
* Get all host-wasmtime tests working with worlds
Various small updates here and there to namings and such.
* Get all Python tests working with worlds
Fix support for exported instances by using correct import paths for
various types/intrinsics/etc. Additionally update the codegen tests to
specify a mypy cache dir to avoid racing between tests.
* Update demo build for worlds
Also fix an issue with the Rust host generator where it used an
interface's name instead of the name of the import for import module names.
* Update demo with world files1 parent 717ab1e commit 0220c95
119 files changed
Lines changed: 2068 additions & 2062 deletions
File tree
- crates
- gen-guest-c
- src
- tests
- gen-guest-rust
- src
- tests
- gen-guest-teavm-java
- src
- tests
- gen-host-js
- src
- tests
- gen-host-wasmtime-py
- src
- tests
- gen-host-wasmtime-rust
- src
- tests
- test-helpers
- macros
- src
- wasi_snapshot_preview1
- src
- wit-bindgen-demo
- src
- wit-parser/src
- src/bin
- tests
- codegen
- runtime
- exports_only
- flavorful
- invalid
- lists
- many_arguments
- numbers
- records
- results
- smoke
- strings
- unions
- variants
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
75 | | - | |
| 75 | + | |
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
91 | | - | |
| 91 | + | |
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
| 107 | + | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
| |||
294 | 294 | | |
295 | 295 | | |
296 | 296 | | |
| 297 | + | |
297 | 298 | | |
298 | 299 | | |
299 | 300 | | |
300 | 301 | | |
301 | 302 | | |
302 | 303 | | |
| 304 | + | |
303 | 305 | | |
304 | 306 | | |
305 | 307 | | |
| |||
325 | 327 | | |
326 | 328 | | |
327 | 329 | | |
| 330 | + | |
328 | 331 | | |
329 | 332 | | |
330 | 333 | | |
| |||
483 | 486 | | |
484 | 487 | | |
485 | 488 | | |
486 | | - | |
| 489 | + | |
487 | 490 | | |
488 | 491 | | |
489 | 492 | | |
| |||
520 | 523 | | |
521 | 524 | | |
522 | 525 | | |
523 | | - | |
| 526 | + | |
524 | 527 | | |
525 | 528 | | |
526 | 529 | | |
| |||
603 | 606 | | |
604 | 607 | | |
605 | 608 | | |
606 | | - | |
| 609 | + | |
607 | 610 | | |
608 | 611 | | |
609 | 612 | | |
| |||
655 | 658 | | |
656 | 659 | | |
657 | 660 | | |
658 | | - | |
| 661 | + | |
659 | 662 | | |
660 | 663 | | |
661 | 664 | | |
662 | 665 | | |
663 | | - | |
| 666 | + | |
664 | 667 | | |
665 | 668 | | |
666 | 669 | | |
| |||
732 | 735 | | |
733 | 736 | | |
734 | 737 | | |
735 | | - | |
| 738 | + | |
736 | 739 | | |
737 | 740 | | |
738 | 741 | | |
| |||
851 | 854 | | |
852 | 855 | | |
853 | 856 | | |
854 | | - | |
| 857 | + | |
855 | 858 | | |
856 | 859 | | |
857 | 860 | | |
| |||
958 | 961 | | |
959 | 962 | | |
960 | 963 | | |
961 | | - | |
| 964 | + | |
962 | 965 | | |
963 | 966 | | |
964 | 967 | | |
| |||
970 | 973 | | |
971 | 974 | | |
972 | 975 | | |
973 | | - | |
| 976 | + | |
974 | 977 | | |
975 | 978 | | |
976 | 979 | | |
| |||
2070 | 2073 | | |
2071 | 2074 | | |
2072 | 2075 | | |
2073 | | - | |
| 2076 | + | |
2074 | 2077 | | |
2075 | 2078 | | |
2076 | 2079 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | | - | |
| 6 | + | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | 13 | | |
15 | 14 | | |
16 | 15 | | |
17 | 16 | | |
18 | 17 | | |
19 | | - | |
| 18 | + | |
20 | 19 | | |
21 | 20 | | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
| 24 | + | |
38 | 25 | | |
39 | 26 | | |
40 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
| 89 | + | |
89 | 90 | | |
90 | 91 | | |
91 | 92 | | |
| |||
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
| 100 | + | |
99 | 101 | | |
100 | 102 | | |
101 | 103 | | |
| |||
111 | 113 | | |
112 | 114 | | |
113 | 115 | | |
114 | | - | |
| 116 | + | |
115 | 117 | | |
116 | 118 | | |
117 | 119 | | |
| |||
122 | 124 | | |
123 | 125 | | |
124 | 126 | | |
125 | | - | |
| 127 | + | |
126 | 128 | | |
127 | 129 | | |
128 | 130 | | |
129 | 131 | | |
130 | | - | |
| 132 | + | |
131 | 133 | | |
132 | 134 | | |
133 | 135 | | |
| |||
237 | 239 | | |
238 | 240 | | |
239 | 241 | | |
| 242 | + | |
240 | 243 | | |
241 | 244 | | |
242 | 245 | | |
| |||
374 | 377 | | |
375 | 378 | | |
376 | 379 | | |
| 380 | + | |
377 | 381 | | |
378 | 382 | | |
379 | 383 | | |
| |||
443 | 447 | | |
444 | 448 | | |
445 | 449 | | |
| 450 | + | |
446 | 451 | | |
447 | 452 | | |
448 | 453 | | |
| |||
662 | 667 | | |
663 | 668 | | |
664 | 669 | | |
665 | | - | |
| 670 | + | |
666 | 671 | | |
667 | 672 | | |
668 | 673 | | |
669 | 674 | | |
670 | 675 | | |
671 | | - | |
672 | | - | |
673 | | - | |
674 | | - | |
675 | | - | |
676 | | - | |
677 | | - | |
678 | | - | |
679 | | - | |
680 | | - | |
681 | | - | |
682 | | - | |
683 | | - | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
684 | 686 | | |
685 | 687 | | |
686 | 688 | | |
| |||
1312 | 1314 | | |
1313 | 1315 | | |
1314 | 1316 | | |
1315 | | - | |
1316 | | - | |
| 1317 | + | |
| 1318 | + | |
1317 | 1319 | | |
1318 | 1320 | | |
1319 | 1321 | | |
| |||
0 commit comments