dpn-admin / dpn-bagit

A rough, pure-ruby implementation of the DPN BagIt spec.
MIT License
1 stars 1 forks source link

Simplecov #2

Closed dazza-codes closed 8 years ago

dazza-codes commented 8 years ago

Enable code coverage using Simplecov

malakai97 commented 8 years ago

Are you planning on using simplecov to flesh out the test suite? I've defaulted to codeclimate in the past, but it's not a strong preference. How does this affect the workflow?

We should prefer double-quoted strings over single-quotes in all cases.

dazza-codes commented 8 years ago

Yes, the aim is to improve the test coverage. We have used simplecov with coveralls and I've seen that other dpn-admin projects use codeclimate. I like simplecov because it can be used on my laptop and it can be combined with coveralls. Perhaps it can be combined with codeclimate too?

quotes: in ruby, single quotes are not interpreted, while double quotes are interpreted (it's like bash in this respect). The use of single quotes is supposed to more efficient for the ruby interpreter when there is no interpolation required. Hence, the 'default' style for strings is to use single quotes in ruby and only use double quotes for interpolations. But, I have no strong personal preference and there is debate in the ruby community -- here's a curious summary, http://anti-pattern.com/always-use-double-quoted-strings-in-ruby. If you have a strong preference for double quotes, I can remove those changes in this PR (and there should be a way to configure rubocop to use that style).

dazza-codes commented 8 years ago

Modified this PR to keep double quotes and simply add simplecov. If this conflicts with codeclimate and it could be used instead, we could close this PR when codeclimate is enabled.