http://qs321.pair.com?node_id=11127420


in reply to Re: Critique requested for module code - QuickMemo+ reader
in thread Critique requested for module code - QuickMemo+ reader

This is a very, very simple distribution so 100% coverage or at minimum extremely close to it should be trivial.

Part of the problem I had with writing tests was that it is difficult to trigger some of the Archive::Zip errors. To test for read errors I used a hex editor to garble the JSON file in the zip archive and was able to trigger that one. To me that seems like an unlikely edge case but I'll continue looking at other modules for more examples of what to test. It's such a small module there aren't a lot of things to test. Testing warnings and carp is something I just recently found so I was happy and proud to get that to work. I found myself bulletproofing the code as I wrote the tests and thought of things that could go wrong.

Thanks for all the suggestions so far!

  • Comment on Re^2: Critique requested for module code - QuickMemo+ reader