From 6d5d939363f11e494dfa4a1a2d1d83b162f09b90 Mon Sep 17 00:00:00 2001 From: "cko-developer-portal[bot]" <89167155+cko-developer-portal[bot]@users.noreply.github.com> Date: Tue, 18 Jul 2023 16:48:28 +0000 Subject: [PATCH] Add CodeQL GitHub Actions workflow --- .github/workflows/codeql-analysis.yml | 50 +++++++++++++++++++ .../CheckoutAPIServiceIntegrationTests.swift | 2 +- 2 files changed, 51 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/codeql-analysis.yml diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml new file mode 100644 index 00000000..1dcbba80 --- /dev/null +++ b/.github/workflows/codeql-analysis.yml @@ -0,0 +1,50 @@ +name: "Run CodeQL" + +on: + push: + branches: + - 'main' + - 'develop' + - 'release/*' + pull_request: + # The branches below must be a subset of the branches above + branches: + - 'main' + - 'develop' + - 'release/*' + schedule: + - cron: '34 2 * * 0' + +jobs: + analyze: + name: Analyze + runs-on: [ macos-latest ] + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'swift' ] + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + submodules: recursive + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v2 + with: + languages: ${{ matrix.language }} + queries: security-and-quality + + - name: Build + run: | + xcodebuild -scheme Frames -destination "platform=iOS Simulator,name=iPhone 14 Pro,OS=latest" + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v2 diff --git a/CheckoutTests/Integration/CheckoutAPIServiceIntegrationTests.swift b/CheckoutTests/Integration/CheckoutAPIServiceIntegrationTests.swift index 8dc60b37..3b59d8c0 100644 --- a/CheckoutTests/Integration/CheckoutAPIServiceIntegrationTests.swift +++ b/CheckoutTests/Integration/CheckoutAPIServiceIntegrationTests.swift @@ -139,7 +139,7 @@ final class CheckoutAPIServiceIntegrationTests: XCTestCase { XCTAssertNil(tokenDetails.billingAddress) XCTAssertEqual(tokenDetails.cardCategory, "CONSUMER") XCTAssertEqual(tokenDetails.cardType, "DEBIT") - XCTAssertEqual(tokenDetails.issuer, "CURVE UK LIMITED") + XCTAssertEqual(tokenDetails.issuer, "WISE PAYMENTS LIMITED") XCTAssertEqual(tokenDetails.issuerCountry, "GB") XCTAssertNil(tokenDetails.phone) XCTAssertEqual(tokenDetails.productId, "MDW")