GitHub Action to run your Swift or Objective-C tests automatically instrumented with CI Visibility Swift Testing framework. It supports Xcode projects as well as Swift Package Manager packages for iOS, macOS and tvOS platforms.
CI Visibility brings together information about CI test and pipeline results plus data about CI performance, trends, and reliability, all into one place. Not only does it provide developers with the ability to dig into the reasons for a test or pipeline failure, to monitor trends in test suite execution times, or to see the effect a given commit has on the pipeline, it also gives build engineers visibility into cross-organization CI health and trends in pipeline performance over time.
-
Set Datadog API key inside Settings > Secrets as
DD_API_KEY
. -
Set Datadog Application key inside Settings > Secrets as
DD_APP_KEY
. -
Add a step to your GitHub Actions workflow YAML that uses this action:
steps: - name: Checkout uses: actions/checkout@v3 - name: Run tests with Datadog uses: Datadog/swift-test-action@v1 with: api_key: ${{ secrets.DD_API_KEY }} app_key: ${{ secrets.DD_APP_KEY }}
These are the optional parameters of the action:
platform: Platform to run: "ios", "macos" or "tvos". By default: "ios"
workspace: .xcworkspace file, if not set, workspace will be autoselected
project: .xcodeproj file, if not set, project will be autoselected
scheme: Scheme to test, if not set, scheme will be autoselected
sdk: SDK used for building, by default: "iphonesimulator" will be used
destination: Destination for testing, by default: "platform=iOS Simulator,name=iPhone 13"
configuration: Configuration for testing, by default: "Debug"
libraryVersion: Version of the Datagog SDK testing framework to use for testing, by default the latest stable
extraParameters: These input will be added directly to the build/test command
There are also extra configuration values that can be set using environment values to the action as specified in the Swift framework documentation