Skip to content

Commit

Permalink
added release stage
Browse files Browse the repository at this point in the history
  • Loading branch information
Rakib committed Jan 18, 2024
1 parent 2bd2cbb commit e0dfe2f
Showing 1 changed file with 60 additions and 60 deletions.
120 changes: 60 additions & 60 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
workflow_dispatch:
# workflow_dispatch:

jobs:

Expand All @@ -15,26 +15,26 @@ jobs:
- name: Checkout Repository
uses: actions/checkout@v3

# - name: Run Lint
# run: echo Run Lint

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'adopt'
java-version: '17'

- name: Make gradlew executable
run: chmod +x ./gradlew

- name: Run Lint
run: echo Run Lint
run: ./gradlew lintDebug

# - name: Set up JDK 17
# uses: actions/setup-java@v3
# with:
# distribution: 'adopt'
# java-version: '17'
#
# - name: Make gradlew executable
# run: chmod +x ./gradlew
#
# - name: Run Lint
# run: ./gradlew lintDebug
#
# - name: Upload html test report
# uses: actions/upload-artifact@v3
# with:
# name: lint.html
# path: app/build/reports/lint-results-debug.html
- name: Upload html test report
uses: actions/upload-artifact@v3
with:
name: lint.html
path: app/build/reports/lint-results-debug.html

unit-test:
needs: [lint]
Expand All @@ -43,26 +43,26 @@ jobs:
- name: Checkout the code
uses: actions/checkout@v3

- name: Run unit-test
run: echo Run unit-test
# - name: Run unit-test
# run: echo Run unit-test

# - name: Set up JDK 17
# uses: actions/setup-java@v3
# with:
# distribution: 'adopt'
# java-version: '17'
#
# - name: Make gradlew executable
# run: chmod +x ./gradlew
#
# - name: Run tests
# run: ./gradlew test
#
# - name: Upload test report
# uses: actions/upload-artifact@v3
# with:
# name: unit-test-report
# path: app/build/reports/tests/testDebugUnitTest/
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'adopt'
java-version: '17'

- name: Make gradlew executable
run: chmod +x ./gradlew

- name: Run tests
run: ./gradlew test

- name: Upload test report
uses: actions/upload-artifact@v3
with:
name: unit-test-report
path: app/build/reports/tests/testDebugUnitTest/

instrumentation-test:
needs: [unit-test]
Expand All @@ -71,29 +71,29 @@ jobs:
- name: Checkout the code
uses: actions/checkout@v3

- name: Run instrumentation-test
run: echo Run instrumentation-test
# - name: Run instrumentation-test
# run: echo Run instrumentation-test

# - name: Set up JDK 17
# uses: actions/setup-java@v3
# with:
# distribution: 'adopt'
# java-version: '17'
#
# - name: Make gradlew executable
# run: chmod +x ./gradlew
#
# - name: Run espresso tests
# uses: reactivecircus/android-emulator-runner@v2
# with:
# api-level: 29
# script: ./gradlew connectedCheck
#
# - name: Upload test report
# uses: actions/upload-artifact@v3
# with:
# name: instrumentation-test-report
# path: app/build/reports/androidTests/connected/debug/
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'adopt'
java-version: '17'

- name: Make gradlew executable
run: chmod +x ./gradlew

- name: Run espresso tests
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 29
script: ./gradlew connectedCheck

- name: Upload test report
uses: actions/upload-artifact@v3
with:
name: instrumentation-test-report
path: app/build/reports/androidTests/connected/debug/

static-code-analysis:
needs: [instrumentation-test]
Expand Down

0 comments on commit e0dfe2f

Please sign in to comment.