name: Build and Run Offline Tests

on: 
  pull_request:
    paths-ignore:
      - '.github/ISSUE_TEMPLATE/*'
      - '.github/PULL_REQUEST_TEMPLATE.md'
      - 'changelog.md'
      - 'LICENSE'
      - 'README.md'
      - 'responsible_disclosure.md'
      - 'SWIFTLINT.md'
      - 'docs/**'

jobs:
  build:
    permissions:
          contents: read
    
    runs-on: macos-12

    steps:
    - uses: actions/checkout@a12a3943b4bdde767164f792f33f40b04645d846
      timeout-minutes: 1
    - name: Build ZcashLightClientKit Swift Package
      timeout-minutes: 15
      run: swift build -v
    - name: Run OfflineTests suite
      timeout-minutes: 5
      run: swift test --filter OfflineTests
