Skip to content

SDK-5763: [Android Core SDK] Add DisplayUnitCache interface + setter on CleverTapAPI (#999) #254

SDK-5763: [Android Core SDK] Add DisplayUnitCache interface + setter on CleverTapAPI (#999)

SDK-5763: [Android Core SDK] Add DisplayUnitCache interface + setter on CleverTapAPI (#999) #254

name: Develop -> Master (SDK Release)
on:
pull_request:
branches: [ master ]
# Cancel in-progress runs when a new commit is pushed
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
# Mandatory file changes check (must pass first)
mandatory-checks:
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
name: Mandatory File Changes
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Mandatory File Changes
uses: ./.github/mini_flows/mandatory_filechanges
# Code Quality Checks (Run in Parallel after mandatory checks)
lint:
needs: [mandatory-checks]
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
name: Code Quality - lint
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Run lint
uses: ./.github/mini_flows/lint
detekt:
needs: [mandatory-checks]
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
name: Code Quality - detekt
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Static Code Check Via detekt
uses: ./.github/mini_flows/codechecks_detekt
checkstyle:
needs: [mandatory-checks]
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
name: Code Quality - checkstyle
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Static Code Check Via checkstyle
uses: ./.github/mini_flows/codechecks_checkstyle
# Unit Tests and Coverage (Only after quality checks pass)
test:
needs: [lint, detekt, checkstyle]
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
pull-requests: write
name: Unit Tests and Coverage
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Unit Tests and Jacoco Coverage (DEBUG)
uses: ./.github/mini_flows/test_and_coverage_debug
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
baseline-branch: master
# Build (Only after tests pass)
build:
needs: [test]
if: github.head_ref == 'develop'
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
name: Build Release AARs
steps:
- name: Checkout the code from Repo
uses: actions/checkout@v4
- name: Setup JDK 17
uses: ./.github/mini_flows/setup_jdk
- name: Build Release AARs
uses: ./.github/mini_flows/build_code_release