DotCoverRakeTask 1.0.1 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/DotCoverRakeTask.rb +19 -5
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ee1563f026546e43b66159d0367de3167acc60c0
4
- data.tar.gz: b67c9cc73d6a87685b0d592dde5df63ecad6f801
3
+ metadata.gz: c001fdcf2aeab43e8ce366e20727e7da6362a511
4
+ data.tar.gz: c4eb337aa97921caeaacf971cb83dc81c1613828
5
5
  SHA512:
6
- metadata.gz: dabe2e4abc2151fabd50b9fd73a49764fd71bcc7042ba2501044dbb249e1b139b3efec83d8591491f5a1e6c7f203150c391d875d2380f4c6dec0c1d53697700d
7
- data.tar.gz: bf974cb050021e5512a4d3df719844a74b27ca9ebede19179a542eaf756ad0e6b65d5b701273fca983372ebfca04d10928c083bc20963ae99d0e2558c0719aca
6
+ metadata.gz: be1517807802ac10fe61daa0daa9aca735710772d8615716c1be56eaa13b61dcc0d9a99286c6cbb7acab914307d1b43123e44e5d0ec443c0ada72efdd012dca8
7
+ data.tar.gz: 73e5b55679fecd82241febdf751203e291a723c51d8ae9c21ad19dde7639f114470cb6d048da9b1a61e41103eae0729bebbeb53b0d1d0b19dc4b17d9eda339eb
@@ -1,6 +1,6 @@
1
1
  include Rake::DSL
2
2
 
3
- def dotCover(*args, &block)
3
+ def dotcover(*args, &block)
4
4
  dotcover_wrapper = DotCoverWrapper.new(&block)
5
5
  task = Proc.new { dotcover_wrapper.run }
6
6
  Rake::Task.define_task(*args, &task)
@@ -16,9 +16,21 @@ class DotCoverWrapper
16
16
  @block.call(configuration)
17
17
  nunit_command_line_args = "#{configuration.nunit_assemblies.join(' ')} #{configuration.nunit_parameters.join(' ')}"
18
18
 
19
- output = `#{configuration.executable} analyse /TargetExecutable=#{configuration.nunit_executable} /TargetArguments="#{nunit_command_line_args}" /Output=#{configuration.output} /Filters=#{configuration.filters} /ReportType=#{configuration.report_type}`
20
-
19
+ output = `#{configuration.executable} cover /TargetExecutable=#{configuration.nunit_executable} /TargetArguments="#{nunit_command_line_args}" /Output=#{configuration.snapshot_file} /Filters=#{configuration.filters}`
21
20
  puts output
21
+
22
+ if (configuration.html_report)
23
+ report = "#{configuration.report_name}.html"
24
+ output = `#{configuration.executable} report /Source="#{configuration.snapshot_file}" /Output="#{report}" /ReportType="HTML"`
25
+ puts output
26
+ end
27
+
28
+ if (configuration.xml_report)
29
+ report = "#{configuration.report_name}.xml"
30
+ output = `#{configuration.executable} report /Source="#{configuration.snapshot_file}" /Output="#{report}" /ReportType="XML"`
31
+ puts output
32
+ end
33
+
22
34
  end
23
35
  end
24
36
 
@@ -27,7 +39,9 @@ class DotCoverConfiguration
27
39
  :nunit_parameters,
28
40
  :executable,
29
41
  :nunit_executable,
30
- :output,
31
- :report_type,
42
+ :snapshot_file,
43
+ :report_name,
44
+ :html_report,
45
+ :xml_report
32
46
  :filters
33
47
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: DotCoverRakeTask
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - iainjmitchell
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-04-30 00:00:00.000000000 Z
12
+ date: 2014-05-01 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description:
15
15
  email: iainjmitchell@gmail.com