name: Continuous Integration

on: [push]

jobs:
  xcode-build:
    name: Xcode Build
    runs-on: macOS-latest
    strategy:
      matrix:
        destination: [
          "platform=macOS",
          "platform=iOS Simulator,name=iPhone Xs", 
          "platform=tvOS Simulator,name=Apple TV",
          "platform=watchOS Simulator,name=Apple Watch Series 4 - 44mm"
        ]

    steps:
    - uses: actions/checkout@v1
    - name: xcrun xcodebuild build
      run: xcrun xcodebuild build -destination "${{ matrix.destination }}" -project "Differ.xcodeproj" -scheme "Differ"

  xcode-test:
    name: Xcode Test
    runs-on: macOS-latest
    strategy:
      matrix:
        destination: [
          "platform=macOS",
          "platform=iOS Simulator,name=iPhone Xs", 
          "platform=tvOS Simulator,name=Apple TV"
        ]

    steps:
    - uses: actions/checkout@v1
    - name: xcrun xcodebuild test
      run: |
        xcrun xcodebuild test -destination "${{ matrix.destination }}" -project "Differ.xcodeproj" -scheme "Differ"
        bash <(curl -s https://codecov.io/bash)

  swift-package-manager-test:
    name: Swift Package Manager
    runs-on: macOS-latest
    
    steps:
    - uses: actions/checkout@v1
    - name: swift test
      run: swift test

name: Continuous Integration

on: [push]

jobs:
  xcode-build:
    name: Xcode Build
    runs-on: macOS-latest
    strategy:
      matrix:
        destination: [
          "platform=macOS",
          "platform=iOS Simulator,name=iPhone Xs", 
          "platform=tvOS Simulator,name=Apple TV",
          "platform=watchOS Simulator,name=Apple Watch Series 4 - 44mm"
        ]

    steps:
    - uses: actions/checkout@v1
    - name: xcrun xcodebuild build
      run: xcrun xcodebuild build -destination "${{ matrix.destination }}" -project "Differ.xcodeproj" -scheme "Differ"

  xcode-test:
    name: Xcode Test
    runs-on: macOS-latest
    strategy:
      matrix:
        destination: [
          "platform=macOS",
          "platform=iOS Simulator,name=iPhone Xs", 
          "platform=tvOS Simulator,name=Apple TV"
        ]

    steps:
    - uses: actions/checkout@v1
    - name: xcrun xcodebuild test
      run: |
        xcrun xcodebuild test -destination "${{ matrix.destination }}" -project "Differ.xcodeproj" -scheme "Differ"
        bash <(curl -s https://codecov.io/bash)

  swift-package-manager-test:
    name: Swift Package Manager
    runs-on: macOS-latest
    
    steps:
    - uses: actions/checkout@v1
    - name: swift test
      run: swift test
      
  cocoapods-verify:
    name: CocoaPods
    runs-on: macOS-latest
    
    steps:
    - uses: actions/checkout@v1
    - name: Lint CocoaPods specification
      run: pod lib lint

Verify the podspec as part of the CI action
Verify the podspec as part of the CI action