fastlane-community / danger-xcov

Danger plugin to validate the code coverage of the files changed in a pull request

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Plugin seems to break when used with xcov 1.1

fwal opened this issue · comments

Gems:

danger 4.3.0
danger-xcov 0.2.2
xcov 1.1.0

Dangerfile:

xcov.report(
  scheme: 'AppKit',
  workspace: 'iOS/App.xcworkspace',
  minimum_coverage_percentage: 80
)

Output:

bundle exec danger --dangerfile=PostBuild.dangerfile --danger_id=postbuild
[09:46:49]: Skipping file blacklisting as no ignore file was found at path 
[09:46:49]: $ xcodebuild -list -workspace iOS/App.xcworkspace
[!] The exception involves the following plugins:
 -  danger-xcov
bundler: failed to load command: danger (/Users/jenkins/.gem/bin/danger)
Danger::DSLError: 
[!] Invalid `PostBuild.dangerfile` file: uninitialized constant Xcov::Runner
 #  from PostBuild.dangerfile:6
 #  -------------------------------------------
 #  if has_kit_changes
 >    xcov.report(
 #      scheme: 'AppKit',
 #  -------------------------------------------

  /Users/jenkins/.gem/gems/danger-xcov-0.2.2/lib/danger_plugin.rb:54:in `report'
  PostBuild.dangerfile:6:in `block in parse'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/dangerfile.rb:199:in `eval'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/dangerfile.rb:199:in `block in parse'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/dangerfile.rb:195:in `instance_eval'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/dangerfile.rb:195:in `parse'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/dangerfile.rb:272:in `run'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/danger_core/executor.rb:27:in `run'
  /Users/jenkins/.gem/gems/danger-4.3.0/lib/danger/commands/runner.rb:66:in `run'
  /Users/jenkins/.gem/gems/claide-1.0.1/lib/claide/command.rb:334:in `run'
  /Users/jenkins/.gem/gems/danger-4.3.0/bin/danger:5:in `<top (required)>'
  /Users/jenkins/.gem/bin/danger:22:in `load'
  /Users/jenkins/.gem/bin/danger:22:in `<top (required)>'

Worked previously with xcov 1.0.1

Hey @fwal 👋

Thanks for reporting! I've just released new xcov and danger-xcov versions fixing this issue. Let me know if it works now for you.

Works like a charm, thanks for the swift response @nakiostudio! 🙌