Skip to content

feat: Added Api Key support and new tests. #32

feat: Added Api Key support and new tests.

feat: Added Api Key support and new tests. #32

Workflow file for this run

# This workflow will build a Swift project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-swift
name: Swift
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- uses: swift-actions/setup-swift@v1
with:
swift-version: "5"
- name: Setup secrets.json
run: |
echo '
{
"hostname": "${{ secrets.SQ_LITE_CLOUD_HOST }}",
"username": "${{ secrets.SQ_LITE_CLOUD_USER }}",
"password": "${{ secrets.SQ_LITE_CLOUD_PASS }}"
}
' >> Tests/SQLiteCloudTests/Secrets/secrets.json
- name: Build
run: swift build -v
- name: Run tests
run: swift test --enable-code-coverage -v
- name: Setup Xcode
uses: maxim-lobanov/[email protected]
with:
xcode-version: "15.2.0"
- name: Gather code coverage
run: xcrun llvm-cov export -format="lcov" .build/debug/SQLiteCloudPackageTests.xctest/Contents/MacOS/SQLiteCloudPackageTests -instr-profile .build/debug/codecov/default.profdata > coverage_report.lcov
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: fail
files: ./coverage_report.lcov
verbose: true