samuelcolvin / python-devtools

Dev tools for python
https://python-devtools.helpmanual.io/
MIT License
974 stars 48 forks source link

Add multi line string option to insert_assert #140

Open NiallRees opened 1 year ago

NiallRees commented 1 year ago

It is sometimes desirable to use a multi line string to improve readability rather than using \n, it would be great if insert_assert supported this as a kwarg to replace with a multi line string.

alexmojaki commented 6 months ago

You might be interested in https://github.com/15r10nk/inline-snapshot which offers similar functionality to insert_assert and uses multiline strings when it thinks it should: https://15r10nk.github.io/inline-snapshot/#code-generation