diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..07b9d2a --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,61 @@ +name: CI +on: + pull_request: + types: [opened, synchronize, reopened] + push: + branches: [master] +jobs: + test: + runs-on: macos-latest + steps: + - name: Clone Repo + uses: actions/checkout@v1 + - name: Gem Cache + uses: actions/cache@v1 + with: + path: vendor/bundle + key: ${{ runner.os }}-gem-${{ hashFiles('**/Gemfile.lock') }} + restore-keys: | + ${{ runner.os }}-gem- + - name: Cocoapod Cache + uses: actions/cache@v1 + with: + path: Pods + key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }} + restore-keys: | + ${{ runner.os }}-pods- + - name: Bundle Install + run: bundle --path vendor/bundle + - name: Pod Install + run: | + bundle exec pod install + - name: Run Tests + run: | + bundle exec fastlane test + coverage: + runs-on: macos-latest + steps: + - name: Clone Repo + uses: actions/checkout@v1 + - name: Gem Cache + uses: actions/cache@v1 + with: + path: vendor/bundle + key: ${{ runner.os }}-gem-${{ hashFiles('**/Gemfile.lock') }} + restore-keys: | + ${{ runner.os }}-gem- + - name: Cocoapod Cache + uses: actions/cache@v1 + with: + path: Pods + key: ${{ runner.os }}-pods-${{ hashFiles('**/Podfile.lock') }} + restore-keys: | + ${{ runner.os }}-pods- + - name: Bundle Install + run: bundle --path vendor/bundle + - name: Pod Install + run: | + bundle exec pod install + - name: Generate Coverage + run: | + bundle exec fastlane coverage