diff --git a/.github/workflows/xcodebuild.yml b/.github/workflows/xcodebuild.yml new file mode 100644 index 0000000..ba7fc2b --- /dev/null +++ b/.github/workflows/xcodebuild.yml @@ -0,0 +1,59 @@ +name: Xcode Build + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + workflow_dispatch: + +jobs: + build-macos: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build macOS + run: xcodebuild -scheme FHDiffableViewControllers -destination 'variant=Mac Catalyst' + - name: Run macOS tests + run: xcodebuild -scheme FHDiffableViewControllers -destination 'variant=Mac Catalyst' test + + build-ios: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build iOS + run: xcodebuild -scheme FHDiffableViewControllers -sdk iphoneos -destination 'name=iPhone 12' + - name: Run iOS tests + run: xcodebuild -scheme FHDiffableViewControllers -sdk iphoneos -destination 'name=iPhone 12' test + + build-ios-simulator: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build iOS + run: xcodebuild -scheme FHDiffableViewControllers -sdk iphonesimulator -destination 'name=iPhone 12' + - name: Run iOS tests + run: xcodebuild -scheme FHDiffableViewControllers -sdk iphonesimulator -destination 'name=iPhone 12' test + + build-tvos: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build iOS + run: xcodebuild -scheme FHDiffableViewControllers -sdk appletvos -destination 'name=Apple TV' + - name: Run iOS tests + run: xcodebuild -scheme FHDiffableViewControllers -sdk appletvos -destination 'name=Apple TV' test + + build-tvos-simulator: + runs-on: macos-latest + + steps: + - uses: actions/checkout@v2 + - name: Build iOS + run: xcodebuild -scheme FHDiffableViewControllers -sdk appletvsimulator -destination 'name=Apple TV' + - name: Run iOS tests + run: xcodebuild -scheme FHDiffableViewControllers -sdk appletvsimulator -destination 'name=Apple TV' test