Hash :
f9b4cb8f
Author :
Date :
2016-12-15T16:47:41
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 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169
# Coverage
This file is just a collection of unit tests not covered elsewhere.
Most notably regression tests, tests improving code coverage and other useful
things may drop here.
(However any tests requiring any additional command line option, like enabling
an extension, must be included in their respective files.)
## GitHub Issues
### [Issue 2](https://github.com/mity/md4c/issues/2)
Raw HTML block:
```````````````````````````````` example
<gi att1=tok1 att2=tok2>
.
<gi att1=tok1 att2=tok2>
````````````````````````````````
Inline:
```````````````````````````````` example
foo <gi att1=tok1 att2=tok2> bar
.
<p>foo <gi att1=tok1 att2=tok2> bar</p>
````````````````````````````````
Inline with a line break:
```````````````````````````````` example
foo <gi att1=tok1
att2=tok2> bar
.
<p>foo <gi att1=tok1
att2=tok2> bar</p>
````````````````````````````````
### [Issue 4](https://github.com/mity/md4c/issues/4)
```````````````````````````````` example
![alt text with *entity* ©](img.png 'title')
.
<p><img src="img.png" alt="alt text with entity ©" title="title"></p>
````````````````````````````````
### [Issue 9](https://github.com/mity/md4c/issues/9)
```````````````````````````````` example
> [foo
> bar]: /url
>
> [foo bar]
.
<blockquote>
<p><a href="/url">foo
bar</a></p>
</blockquote>
````````````````````````````````
### [Issue 10](https://github.com/mity/md4c/issues/10)
```````````````````````````````` example
[x]:
x
- <?
x
.
<ul>
<li><?
<p>x</p>
</li>
</ul>
````````````````````````````````
### [Issue 11](https://github.com/mity/md4c/issues/11)
```````````````````````````````` example
x [link](/url "foo – bar") x
.
<p>x <a href="/url" title="foo – bar">link</a> x</p>
````````````````````````````````
## Code coverage
### `md_is_unicode_whitespace__()`
Unicode whitespace (here U+2000) forms a word boundary so these cannot be
resolved as emphasis span because there is no closer mark.
```````````````````````````````` example
*foo *bar
.
<p>*foo *bar</p>
````````````````````````````````
### `md_is_unicode_punct__()`
Ditto for Unicode punctuation (here U+00A1).
```````````````````````````````` example
*foo¡*bar
.
<p>*foo¡*bar</p>
````````````````````````````````
### `md_get_unicode_fold_info()`
```````````````````````````````` example
[Příliš žluťoučký kůň úpěl ďábelské ódy.]
[PŘÍLIŠ ŽLUŤOUČKÝ KŮŇ ÚPĚL ĎÁBELSKÉ ÓDY.]: /url
.
<p><a href="/url">Příliš žluťoučký kůň úpěl ďábelské ódy.</a></p>
````````````````````````````````
### `md_decode_utf8__()` and `md_decode_utf8_before__()`
```````````````````````````````` example
á*Á (U+00E1, i.e. two byte UTF-8 sequence)
* (U+2000, i.e. three byte UTF-8 sequence)
.
<p>á*Á (U+00E1, i.e. two byte UTF-8 sequence)
* (U+2000, i.e. three byte UTF-8 sequence)</p>
````````````````````````````````
### `md_is_link_destination_A()`
```````````````````````````````` example
[link](</url\.with\.escape>)
.
<p><a href="/url.with.escape">link</a></p>
````````````````````````````````
### `md_link_label_eq()`
```````````````````````````````` example
[foo bar]
[foo bar]: /url
.
<p><a href="/url">foo bar</a></p>
````````````````````````````````
### `md_is_inline_link_spec()`
```````````````````````````````` example
> [link](/url 'foo
> bar')
.
<blockquote>
<p><a href="/url" title="foo
bar">link</a></p>
</blockquote>
````````````````````````````````