|
13 | 13 | $ odoc link _odoc/pkg/dir1/page-dontent.odoc
|
14 | 14 |
|
15 | 15 | $ odoc compile-index -P test:_odoc/pkg
|
16 |
| - File "index.mld", line 5, characters 30-35: |
| 16 | + File "index.mld", line 1, characters 30-35: |
17 | 17 | Warning: Duplicate 'dir1/' in (children).
|
18 |
| - File "index.mld", line 5, characters 36-40: |
| 18 | + File "index.mld", line 1, characters 36-40: |
19 | 19 | Warning: 'typo' in (children) does not correspond to anything.
|
20 |
| - File "index.mld", line 5, characters 0-40: |
| 20 | + File "index.mld", line 1, characters 0-40: |
21 | 21 | Warning: (children) doesn't include 'omitted'.
|
22 | 22 |
|
23 | 23 | $ odoc html-generate --indent --index index.odoc-index -o _html _odoc/pkg/page-index.odocl
|
@@ -76,17 +76,33 @@ Some more parsing test:
|
76 | 76 |
|
77 | 77 | $ mkdir errors
|
78 | 78 | $ cat << EOF >> errors/index.mld
|
79 |
| - > {0 Test1} |
80 | 79 | > @children_order [Some wrong content]
|
| 80 | + > {0 Test1} |
81 | 81 | > EOF
|
82 | 82 | $ odoc compile --parent-id pkg/doc --output-dir _odoc errors/index.mld
|
83 |
| - File "errors/index.mld", line 2, characters 16-36: |
| 83 | + File "errors/index.mld", line 1, characters 16-36: |
84 | 84 | Warning: Only words are accepted when specifying children order
|
85 | 85 |
|
86 | 86 | $ mkdir valid
|
87 | 87 | $ cat << EOF > valid/index.mld
|
88 |
| - > {0 Test1} |
89 | 88 | > @children_order a
|
90 | 89 | > b c
|
| 90 | + > {0 Test1} |
91 | 91 | > EOF
|
92 | 92 | $ odoc compile --parent-id pkg/doc --output-dir _odoc valid/index.mld
|
| 93 | + |
| 94 | + $ cat << EOF > errors/index.mld |
| 95 | + > {0 Test1} |
| 96 | + > @children_order a |
| 97 | + > EOF |
| 98 | + $ odoc compile --parent-id pkg/doc --output-dir _odoc errors/index.mld |
| 99 | + File "errors/index.mld", line 2, characters 0-17: |
| 100 | + Warning: @children_order tag has to be before any content |
| 101 | + |
| 102 | + $ cat << EOF > errors/not_index.mld |
| 103 | + > @children_order a |
| 104 | + > {0 Test1} |
| 105 | + > EOF |
| 106 | + $ odoc compile --parent-id pkg/doc --output-dir _odoc errors/not_index.mld |
| 107 | + File "errors/not_index.mld": |
| 108 | + Warning: Non-index page cannot specify (children _) in the frontmatter. |
0 commit comments