-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build CI: Trigger when have a PR merged to staging branch
- Loading branch information
Showing
2 changed files
with
32 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Run test | ||
on: | ||
pull_request: | ||
branches: | ||
- staging | ||
jobs: | ||
if_merged: | ||
if: github.event.pull_request.merged == true | ||
name: Test on iOS simulator | ||
runs-on: macOS-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4.1.1 | ||
- name: Java setup | ||
uses: actions/setup-java@v4.0.0 | ||
with: | ||
java-version: '17' | ||
distribution: 'zulu' | ||
- name: Flutter setup | ||
uses: subosito/flutter-action@v2.12.0 | ||
with: | ||
channel: 'stable' | ||
- name: Create iOS simulator | ||
uses: futureware-tech/simulator-action@v3 | ||
with: | ||
model: 'iPhone 14' | ||
- run: flutter doctor -v | ||
- run: flutter pub get | ||
- run: flutter pub run build_runner build --delete-conflicting-outputs | ||
- run: flutter test --flavor=dev | ||
- run: flutter test integration_test --flavor=dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
## The Flutter project integrate CI-CD | ||
Todo ... | ||
![Flutter CI-CD demo](https://github.com/ntaworking/flutter_ci_cd/actions/workflows/main.yml/badge.svg) |