feat: Add test for lib publishing workflow

This commit is contained in:
2023-04-04 16:52:28 +03:00
parent 3b88afa9d8
commit 4ceba8cf7f

View File

@@ -7,6 +7,10 @@ on:
description: "Using for choice specified module when build application."
required: true
type: string
IS_TEST_ENABLED:
description: "Using for start test before pushing to ECR if value is true."
default: false
type: boolean
secrets:
SECRET_GITHUB_TOKEN:
required: true
@@ -30,6 +34,13 @@ jobs:
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Test with Gradle
if: ${{ inputs.IS_TEST_ENABLED }}
run: ./gradlew test -p ${{ inputs.MODULE_NAME }}
env:
GITHUB_TOKEN: ${{ secrets.SECRET_GITHUB_TOKEN }}
GITHUB_USERNAME: ${{ secrets.SECRET_GITHUB_USERNAME }}
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
- name: Publish package