Some work to complete #17, although not yet complete. New is better tested now, ensuring new creates a new direcoty with a file in it, and new --title=test creates a file called test.md and its first line is the provided title.
There were some changes to the new.go command file to accomodate for better testing. Mostly inspired by option 2 from the referenced blog post.
Some work to complete #17, although not yet complete. New is better tested now, ensuring
new
creates a new direcoty with a file in it, andnew --title=test
creates a file called test.md and its first line is the provided title.There were some changes to the
new.go
command file to accomodate for better testing. Mostly inspired by option 2 from the referenced blog post.Ref: https://clavinjune.dev/en/blogs/implement-unit-test-for-cli-apps-using-golang-and-cobra/#option-2