Diff options
| author | Bryce Kwon <bryce@brycekwon.com> | |
|---|---|---|
| committer | Bryce Kwon <bryce@brycekwon.com> | |
| commit | ||
| parent | ||
| tree | ||
| download | ||
Check that the outermost avatar brackets come off
With one pair of brackets, matching the innermost pair would have
passed the old check as well.
Diffstat (limited to 'tests/extensions/test-email-avatar.lua')
| -rw-r--r-- | tests/extensions/test-email-avatar.lua | 4 |
1 file changed, 4 insertions, 0 deletions
diff --git a/tests/extensions/test-email-avatar.lua b/tests/extensions/test-email-avatar.lua index c9a9ec0..bb3668c 100644 --- a/tests/extensions/test-email-avatar.lua +++ b/tests/extensions/test-email-avatar.lua @@ -112,6 +112,10 @@ h.stays_linear("an address of open brackets is scanned in linear time", address_ h.check("text around the brackets is dropped", hash_of(render("x <author@example.com> y", "x")) == plain) +if mode == "stub" then + h.equals("the outermost brackets are the ones taken off", hash_of(render("<a <b> c>", "x")), + "4c40a2581c18aec944a8caa7000e17fa") +end local reversed = hash_of(render("a>b<c", "x")) h.check("a close before the open unwraps nothing", reversed ~= nil and reversed ~= plain) |
