The "test anything protocol" was a text based system for writing tests, I think perl might still use it
I remember using it to implement the test suite for a Shakespeare language interpreter. Fun times.
https://en.wikipedia.org/wiki/Test_Anything_Protocol