README.md in quality-19.2.0 vs README.md in quality-19.2.1
- old
+ new
@@ -55,18 +55,18 @@
```
## Configuration options
```ruby
-Quality::Rake::Task.new { |t|
+Quality::Rake::Task.new do |t|
# Name of quality task.
# Defaults to :quality.
- t.quality_name = "quality"
+ t.quality_name = 'quality'
# Name of ratchet task.
# Defaults to :ratchet.
- t.ratchet_name = "ratchet"
+ t.ratchet_name = 'ratchet'
# Array of strings describing tools to be skipped--e.g., ["cane"]
#
# Defaults to []
t.skip_tools = []
@@ -76,14 +76,16 @@
# Defaults to false
t.verbose = false
# Array of directory names which contain ruby files to analyze.
#
- # Defaults to %w(app lib test spec feature), which translates to *.rb in the base directory, as well as those directories.
+ # Defaults to %w(app lib test spec feature), which translates to
+ # *.rb in the base directory, as well as those directories.
t.ruby_dirs = %w(app lib test spec feature)
- # Array of directory names which contain any type of source files to analyze.
+ # Array of directory names which contain any type of source files to
+ # analyze.
#
# Defaults to t.ruby_dirs
t.source_dirs.concat(%w(MyProject MyProjectTests))
# Pick any extra files that are source files, but may not have
@@ -93,16 +95,18 @@
# Pick any extra files that are source files, but may not have
# extensions--defaults to %w(Rakefile)
t.extra_ruby_files = ['Rakefile']
# Exclude the specified list of files--defaults to ['db/schema.rb']
- t.exclude_files = ['lib/whatever/imported_file.rb', 'lib/vendor/someone_else_fault.rb']
+ t.exclude_files = ['lib/whatever/imported_file.rb',
+ 'lib/vendor/someone_else_fault.rb']
# Alternately, express it as a glob:
# Exclude the specified list of files
- t.source_files_exclude_glob = "{lib/whatever/imported_file.rb,lib/vendor/**/*.rb}"
+ t.source_files_exclude_glob =
+ '{lib/whatever/imported_file.rb,lib/vendor/**/*.rb}'
# Extensions for Ruby language files--defaults to 'rb,rake'
t.ruby_file_extensions_glob = 'rb,rake'
# Extensions for all source files--defaults to
@@ -119,10 +123,10 @@
# Pipe-separated regexp string describing what to look for in
# files as 'todo'-like 'punchlist' comments.
#
# Defaults to 'XXX|TODO'
t.punchlist_regexp = 'XXX|TODO'
-}
+end
```
## Code coverage
You can pull a similar trick with code coverage using SimpleCov in Ruby--put 'simplecov' in your Gemfile, and add the code below into your test_helper.rb or spec_helper.rb.