I'm writing unit tests for a model with an attribute that's interpreted as markdown. I'd like to test that if the markdown is invalid, then the object is invalid - but it's such a forgiving syntax that everything I've tried so far turns out to be valid markdown! What's an example of some invalid markdown?
I haven't used markdown extensively but i was under the impression that it is impossible to write "invalid" markdown only markdown that wont do what you want it to. As in instead of throwing an error when it doesn't know what to do it just treats it as plain text.
On a different path one could probably write a script to try and identify things that the user probably didn't intend, for example if someone entered **test*
they probably intended *test*
or **test**
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With