Skip to content

Upgrade AGP to 8.6.0 #149

Upgrade AGP to 8.6.0

Upgrade AGP to 8.6.0 #149

Workflow file for this run

# MIT License
#
# Copyright (c) 2021, 2022, 2024 ViliusSutkus89.com
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
name: build
on:
workflow_dispatch:
push:
paths-ignore:
- '**.md'
- '.github/**'
- '!.github/workflows/build.yml'
permissions:
actions: none
checks: none
contents: none
deployments: none
issues: none
packages: none
pull-requests: none
repository-projects: none
security-events: none
statuses: none
jobs:
build:
if: "!contains(github.event.head_commit.message, '[SkipCI]')"
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- uses: android-actions/setup-android@v3
- name: setup python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
- name: install python dependencies
run: pip install --upgrade conan
- run: |
conan config install .github/conan
conan profile list
conan profile show
- run: conan remote add odr https://artifactory.opendocument.app/artifactory/api/conan/conan
- run: conan graph info wvWare --profile=android-21-armv8 --build=missing --format=html > conangraph.html
- run: ./gradlew lintRelease publishToMavenLocal
- name: Artifact library-lint-report
uses: actions/upload-artifact@v4
with:
name: library-lint-report
path: wvWare/build/reports/lint-results-release.html
if-no-files-found: error
- name: Artifact maven-local
uses: actions/upload-artifact@v4
with:
name: maven-local
path: ~/.m2
if-no-files-found: error
- name: Artifact conangraph.html
uses: actions/upload-artifact@v4
with:
name: conangraph.html
path: conangraph.html
if-no-files-found: error
- name: Artifact dotconan2
uses: actions/upload-artifact@v4
with:
name: dotconan2
path: ~/.conan2
if-no-files-found: error
compression-level: 0
include-hidden-files: true
emulator:
needs: build
runs-on: ubuntu-22.04
name: android-${{ matrix.emulator.api_level }} on ${{ matrix.emulator.arch }} (${{ matrix.emulator.api_type_target }})
strategy:
fail-fast: false
matrix:
emulator:
# Emulator matrix generated by ci-scripts/emulator_matrix_generator.py
- { 'api_level': 35, 'api_type_target': 'google_apis', 'arch': 'x86_64' }
- { 'api_level': 34, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 33, 'api_type_target': 'aosp_atd', 'arch': 'x86_64' }
- { 'api_level': 32, 'api_type_target': 'aosp_atd', 'arch': 'x86_64' }
- { 'api_level': 31, 'api_type_target': 'aosp_atd', 'arch': 'x86_64' }
- { 'api_level': 30, 'api_type_target': 'aosp_atd', 'arch': 'x86_64' }
- { 'api_level': 30, 'api_type_target': 'aosp_atd', 'arch': 'x86' }
- { 'api_level': 29, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 29, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 28, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 28, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 27, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 27, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 26, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 26, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 25, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 25, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 24, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 24, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 23, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 23, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 22, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 22, 'api_type_target': 'default', 'arch': 'x86' }
- { 'api_level': 21, 'api_type_target': 'default', 'arch': 'x86_64' }
- { 'api_level': 21, 'api_type_target': 'default', 'arch': 'x86' }
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- uses: android-actions/setup-android@v3
- name: setup python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
- run: pip install --upgrade conan adbPullAs selenium Pillow
- uses: actions/download-artifact@v4
with:
name: dotconan2
path: ~/.conan2
- name: Enable KVM group perms
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: Keep APK installed after test run
run: echo "android.injected.androidTest.leaveApksInstalledAfterRun=true" >> gradle.properties
- uses: reactivecircus/android-emulator-runner@v2
with:
force-avd-creation: false
emulator-options: -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none -no-snapshot-save
sdcard-path-or-size: 1G
disk-size: 7G
api-level: ${{ matrix.emulator.api_level }}
arch: ${{ matrix.emulator.arch }}
target: ${{ matrix.emulator.api_type_target }}
script: |
mkdir -p testResults/screenshots
adb logcat > testResults/logcat.txt &
adb shell screencap /data/local/tmp/beforeTests.png
adb pull /data/local/tmp/beforeTests.png testResults/screenshots/
./gradlew connectedCheck || touch sorry_but_tests_are_failing
adbPullAs com.viliussutkus89.android.wvware.test /data/data/com.viliussutkus89.android.wvware.test/cache/wvWare testResults
adb pull /sdcard/Pictures/screenshots testResults/ || true
adb shell screencap /data/local/tmp/afterTests.png
adb pull /data/local/tmp/afterTests.png testResults/screenshots/
mv wvWare/build/reports/androidTests/connected testResults/
mv wvWare/build/outputs/androidTest-results testResults/
test ! -f sorry_but_tests_are_failing
- run: python ci-scripts/browser_tests.py --html-dir testResults/wvWare --png-destination-dir testResults/pngs --reference-png-dir test/reference_pngs
- uses: actions/upload-artifact@v4
if: always()
with:
name: testResults-${{ matrix.emulator.api_level }}-${{ matrix.emulator.arch }}-${{ matrix.emulator.api_type_target }}
path: testResults
if-no-files-found: error