Skip to content

Commit

Permalink
test: add failing test for table after no newline
Browse files Browse the repository at this point in the history
See github/cmark-gfm#154.

This was my doing 🤦‍♀️
  • Loading branch information
kivikakk committed Apr 9, 2021
1 parent 195ef0a commit 165dac7
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,32 @@ fn table() {
);
}

#[test]
fn table_regression() {
html_opts!(
[extension.table],
concat!("123\n", "456\n", "| a | b |\n", "| ---| --- |\n", "d | e\n"),
concat!(
"<p>123\n",
"456</p>\n",
"<table>\n",
"<thead>\n",
"<tr>\n",
"<th>a</th>\n",
"<th>b</th>\n",
"</tr>\n",
"</thead>\n",
"<tbody>\n",
"<tr>\n",
"<td>d</td>\n",
"<td>e</td>\n",
"</tr>\n",
"</tbody>\n",
"</table>\n"
),
);
}

#[test]
fn autolink_www() {
html_opts!(
Expand Down

0 comments on commit 165dac7

Please sign in to comment.