-
Notifications
You must be signed in to change notification settings - Fork 238
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Xcode 9 No product binary found #347
Comments
I had to add the “— binary-files “ command line option to overcome this.
…Sent from my iPhone
On Oct 8, 2017, at 10:20 AM, Sven Bone ***@***.***> wrote:
I'm using Xcode 9 and want to build and test my app by a terminal script in order to setup a local GitLab CI.
xcodebuild
xcodebuild test -project TargetShooter.xcodeproj -scheme TargetShooterTests_Debug -destination 'platform=iOS SImulator,name=iPhone 6s,OS=11.0' -enableCodeCoverage YES | xcpretty -c -s
Everything runs as expected. I'm using the same scheme for the Xcode Server to gather code coverage which works perfectly.
...
✓ testVarianceArrayDouble10Numbers (0.001 seconds)
✓ testVarianceArrayDouble10ZeroNumbers (0.001 seconds)
✓ testVarianceArrayDoubleNil (0.001 seconds)
✓ testVarianceArrayInt10EqualNumbers (0.001 seconds)
✓ testVarianceArrayInt10Numbers (0.001 seconds)
✓ testVarianceArrayInt10ZeroNumbers (0.001 seconds)
✓ testVarianceArrayIntNil (0.001 seconds)
Executed 175 tests, with 0 failures (0 unexpected) in 0.185 (0.311) seconds
Slather
slather coverage -s --scheme TargetShooterTests_Debug --verbose TargetShooter.xcodeproj
I always receive the following error:
Slathering...
No product binary found in /Users/Sven/Library/Developer/Xcode/DerivedData/TargetShooter-adwuwhyvmfikgjbvoxptvzsxseii/Build/Intermediates.noindex/../ProfileData/EA4291D2-59CD-4458-B911-A5268B7DFBBE.
Are you sure your project is generating coverage? Make sure you enable code coverage in the Test section of your Xcode scheme.
Did you specify your Xcode scheme? (--scheme or 'scheme' in .slather.yml)
If you're using a workspace, did you specify it? (--workspace or 'workspace' in .slather.yml)
If you use a different Xcode configuration, did you specify it? (--configuration or 'configuration' in .slather.yml)
/usr/local/lib/ruby/gems/2.4.0/gems/slather-2.4.3/lib/slather/project.rb:481:in `find_binary_files': No product binary found in /Users/Sven/Library/Developer/Xcode/DerivedData/TargetShooter-adwuwhyvmfikgjbvoxptvzsxseii/Build/Intermediates.noindex/../ProfileData/EA4291D2-59CD-4458-B911-A5268B7DFBBE. (StandardError)
from /usr/local/lib/ruby/gems/2.4.0/gems/slather-2.4.3/lib/slather/project.rb:367:in `configure_binary_file'
from /usr/local/lib/ruby/gems/2.4.0/gems/slather-2.4.3/lib/slather/project.rb:251:in `configure'
from /usr/local/lib/ruby/gems/2.4.0/gems/slather-2.4.3/lib/slather/command/coverage_command.rb:54:in `execute'
from /usr/local/lib/ruby/gems/2.4.0/gems/clamp-0.6.5/lib/clamp/command.rb:67:in `run'
from /usr/local/lib/ruby/gems/2.4.0/gems/clamp-0.6.5/lib/clamp/subcommand/execution.rb:11:in `execute'
from /usr/local/lib/ruby/gems/2.4.0/gems/clamp-0.6.5/lib/clamp/command.rb:67:in `run'
from /usr/local/lib/ruby/gems/2.4.0/gems/clamp-0.6.5/lib/clamp/command.rb:132:in `run'
from /usr/local/lib/ruby/gems/2.4.0/gems/slather-2.4.3/bin/slather:17:in `<top (required)>'
from /usr/local/bin/slather:23:in `load'
from /usr/local/bin/slather:23:in `<main>'
Any ideas what's going wrong?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
And how do I identify the correct binary file path? |
By specifying the binary base name I receive the following error.
|
@SvenMuc I'm getting the same error without passing the binary-basename, running --verbose I can see that the .profdata and the binary file can be found, but no coverage data found in the binary search path. |
@SvenMuc I have same issue and resolved it by specifying --build-directory which is your path to derivedData folder |
@vijayviswas Can you please post the full command that is working for you? This is not working for me at the moment. |
@esyd1pi0 I'm using the following commands. Works at least for me. Xcode
Slather
|
Unfortunately none of these solutions work for me. Tried |
@albertodebortoli That's strange. I'm using Xcode 9.0 too. I just used |
I'm using Xcode 9 and want to build and test my app by a terminal script in order to setup a local GitLab CI.
xcodebuild
xcodebuild test -project TargetShooter.xcodeproj -scheme TargetShooterTests_Debug -destination 'platform=iOS SImulator,name=iPhone 6s,OS=11.0' -enableCodeCoverage YES | xcpretty -c -s
Everything runs as expected. I'm using the same scheme for the Xcode Server to gather code coverage which works perfectly.
Slather
slather coverage -s --scheme TargetShooterTests_Debug --verbose TargetShooter.xcodeproj
I always receive the following error:
Any ideas what's going wrong?
The text was updated successfully, but these errors were encountered: