Skip to content

Commit

Permalink
Limit testPlan comment to Xcode >= 11
Browse files Browse the repository at this point in the history
  • Loading branch information
esteluk committed Mar 12, 2020
1 parent da6b226 commit 98df6ac
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion scan/lib/scan/test_command_generator.rb
Expand Up @@ -45,7 +45,9 @@ def options # rubocop:disable Metrics/PerceivedComplexity
options << "-enableCodeCoverage #{config[:code_coverage] ? 'YES' : 'NO'}" unless config[:code_coverage].nil?
options << "-enableAddressSanitizer #{config[:address_sanitizer] ? 'YES' : 'NO'}" unless config[:address_sanitizer].nil?
options << "-enableThreadSanitizer #{config[:thread_sanitizer] ? 'YES' : 'NO'}" unless config[:thread_sanitizer].nil?
options << "-testPlan #{config[:testplan]}" if config[:testplan]
if FastlaneCore::Helper.xcode_at_least?(11)
options << "-testPlan #{config[:testplan]}" if config[:testplan]
end
options << "-xctestrun '#{config[:xctestrun]}'" if config[:xctestrun]
options << config[:xcargs] if config[:xcargs]

Expand Down
2 changes: 1 addition & 1 deletion scan/spec/test_command_generator_spec.rb
Expand Up @@ -624,7 +624,7 @@
log_path = File.expand_path("~/Library/Logs/scan/app-app.log")

result = @test_command_generator.generate
expect(result).to include("-testPlan simple")
expect(result).to include("-testPlan simple") if FastlaneCore::Helper.xcode_at_least?(10)
end
end
end
Expand Down

0 comments on commit 98df6ac

Please sign in to comment.