Skip to content

Sonar run command is failing #285

Open
@pawargb

Description

Issue Description

Command executed

./run-sonar-swift.sh -v

Complete output when running fastlane, including the stack trace and command used

Running run-sonar-swift.sh...
Project count is [1]
2021-02-05 16:24:33.138 defaults[39383:629654]
The domain/default pair of (/Users/ganeshpawar/Documents/Personal/Practice, Swift/SonarTesting/SonarTesting/Info.plist) does not exist
Xcode project file is: SonarTesting.xcodeproj
Xcode workspace file is:
Xcode application scheme is: SonarTesting
Number version from plist is:
Destination simulator is: platform=iOS Simulator,name=iPhone 12 mini,OS=14.2
Excluded paths from coverage are:
Creating directory sonar-reports/
Extracting Xcode project information

  • xcodebuild clean build -project SonarTesting.xcodeproj -scheme SonarTesting -destination 'platform=iOS Simulator,name=iPhone 12 mini,OS=14.2' -destination-timeout 360 COMPILER_INDEX_STORE_ENABLE=NO
  • returnValue=0
  • set +x
    ▸ Clean Succeeded
    ▸ Compiling ViewController.swift
    ▸ Compiling AppDelegate.swift
    ▸ Compiling SceneDelegate.swift
    ▸ Linking SonarTesting normal (in target 'SonarTesting' from
    ▸ Copying /Users/ganeshpawar/Documents/Personal/Practice\ Swift/SonarTesting/sonar-project.properties
    ▸ Copying /Users/ganeshpawar/Documents/Personal/Practice\ Swift/SonarTesting/run-sonar-swift.sh
    ▸ Compiling Main.storyboard
    ▸ Compiling LaunchScreen.storyboard
    ▸ Processing Info.plist
    ▸ Touching SonarTesting.app (in target 'SonarTesting' from project 'SonarTesting')
    ▸ Build Succeeded
    actual = 2, min = 3
    Running surefire
  • xcodebuild clean build test -project SonarTesting.xcodeproj -scheme SonarTesting -configuration MYDebug -enableCodeCoverage YES -destination 'platform=iOS Simulator,name=iPhone 12 mini,OS=14.2' -destination-timeout 60
    Testing failed:
    Module 'SonarTesting' was not compiled for testing
    Testing cancelled because the build failed.

** TEST FAILED **

The following build commands failed:
CompileSwift normal x86_64 /Users/ganeshpawar/Documents/Personal/Practice\ Swift/SonarTesting/SonarTestingTests/SonarTestingTests.swift
CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler
CompileSwift normal arm64 /Users/ganeshpawar/Documents/Personal/Practice\ Swift/SonarTesting/SonarTestingTests/SonarTestingTests.swift
CompileSwiftSources normal arm64 com.apple.xcode.tools.swift.compiler
(4 failures)

  • returnValue=65
  • set +x
    ERROR - Command 'xcodebuild clean build test -project SonarTesting.xcodeproj -scheme SonarTesting -configuration MYDebug -enableCodeCoverage YES -destination platform=iOS Simulator,name=iPhone 12 mini,OS=14.2 -destination-timeout 60' failed with error code: 65
 [REPLACE THIS WITH YOUR INFORMATION] 

Environment

Following below article to integrate SonarQube for iOS App in Xcode(12.2) but failing with above error:

https://medium.com/@pranay.urkude/sonarqube-integration-with-ios-b76df8405014

Activity

B-Yoxtheimer-OH

B-Yoxtheimer-OH commented on Nov 18, 2021

@B-Yoxtheimer-OH

@pawargb i am having the same issue, did you ever find a solution to this? i am wondering if it has something to do with frameworks i have in my project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Sonar run command is failing · Issue #285 · Idean/sonar-swift