Skip to content

Commit

Permalink
Merge branch 'main' into release/4.3
Browse files Browse the repository at this point in the history
* main: (63 commits)
  Update vendor_tools.
  Update tgfx and vendor_tools.
  fix a wild pointer while pagview/pagimageview dealloc (#1847)
  Fix codecov report.
  Fix a missing header.
  Save images to TestDir::GetRoot().
  re-sync the project after updating the baseline cache.
  Add a TestDir class to locate the test directory.
  Update tgfx. (#1845)
  Update GCC version in build prerequisites.
  Fix the wrong file path in PAGTextLayerTest. (#1834)
  Update tgfx.
  Allow passing a custom tgfx directory into cmakelists.
  Remove some tests only for tgfx. (#1822)
  Fix some potential array out-of-bounds errors.
  Add a DevicePool to tests to fix the testing failure caused by the number limit of GPU context creation. (#1820)
  Fix building error of the UpdateBaseline target.
  Skip updating the local md5 cache in UpdateBaseline if any test fails. (#1819)
  Update the tgfx repository URL.
  Update vendor_tools.
  ...

# Conflicts:
#	DEPS
#	test/src/PAGFilterTest.cpp
#	tgfx/src/core/Canvas.cpp
#	tgfx/src/gpu/RenderTarget.h
#	tgfx/src/gpu/Swizzle.h
#	vendor.json
  • Loading branch information
kevingpqi123 committed Nov 9, 2023
2 parents 7605180 + 5d6a74c commit 64f8417
Show file tree
Hide file tree
Showing 866 changed files with 5,899 additions and 253,384 deletions.
150 changes: 76 additions & 74 deletions .github/workflows/autotest.yml
Original file line number Diff line number Diff line change
@@ -1,116 +1,118 @@
# This is a basic workflow to help you get started with Actions

name: autotest

# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the master branch
pull_request:
branches: [ main ]
push:
branches: [ main ]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
autotest:
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: macos-latest

jobs:
mac:
# the macos-latest may randomly give us macos-12.6.9 or macos-12.7.0 which may break the autotest.
runs-on: macos-13
steps:
- name: Get environment cache
id: cache-environment
uses: actions/cache@v2
- name: Check Out Repo
uses: actions/checkout@v3
with:
fetch-depth: 0
lfs: true

- name: Get Environment Cache
id: environment-cache
uses: actions/cache/restore@v3
with:
path: |
/usr/local/Cellar/ninja
/usr/local/Cellar/icu4c
/usr/local/bin/ninja
/usr/local/Cellar/node
/usr/local/bin/node
/usr/local/Cellar/yasm
/usr/local/bin/yasm
/usr/local/bin/depsync
/usr/local/lib/node_modules/depsync
/usr/local/Cellar/gcovr
/usr/local/bin/gcovr
/usr/local/Cellar/emsdk
/usr/local/Cellar/emsdk/upstream/emscripten
/usr/local/Cellar/emsdk/node/14.18.2_64bit/bin
/usr/local/bin/em++
/usr/local/bin/em-config
/usr/local/bin/emar
/usr/local/bin/embuilder
/usr/local/bin/emcc
/usr/local/bin/emcmake
/usr/local/bin/emconfigure
/usr/local/bin/emdump
/usr/local/bin/emdwp
/usr/local/bin/emmake
/usr/local/bin/emnm
/usr/local/bin/emrun
/usr/local/bin/emprofile
/usr/local/bin/emscons
/usr/local/bin/emsize
/usr/local/bin/emstrip
/usr/local/bin/emsymbolizer
/usr/local/bin/emcc.py
/usr/local/bin/emcmake.py
/usr/local/bin/emar.py
key: libpag-environment-autotest-20221018
restore-keys: |
libpag-environment-autotest-20221018
- uses: actions/checkout@v3
with:
fetch-depth: 0
lfs: true
- name: Get thirdParty cache
id: cache-thirdParty
uses: actions/cache@v2
/usr/local/Cellar/python-lxml
/usr/local/Cellar/python-markupsafe
/usr/local/lib/python3.12/site-packages/lxml
/usr/local/lib/python3.12/site-packages/markupsafe
key: libpag-environment-autotest-20231029
restore-keys: libpag-environment-autotest-

- name: Get Third-Party Cache
id: third-party-cache
uses: actions/cache/restore@v3
with:
path: |
third_party
vendor_tools
test/baseline/.cache
key: third_party-autotest-01-${{ hashFiles('DEPS') }}-${{ hashFiles('vendor.json') }}-${{ hashFiles('test/baseline/version.json') }}
restore-keys: third_party-autotest-
- name: Run sync_deps script
key: third-party-autotest-${{ hashFiles('DEPS') }}-${{ hashFiles('vendor.json') }}-${{ hashFiles('test/baseline/version.json') }}
restore-keys: third-party-autotest-

- name: Run depsync
run: |
chmod +x sync_deps.sh
./sync_deps.sh
npm install depsync -g
depsync
shell: bash

- if: github.event_name == 'push'
name: Build cache(push)
- name: Check Code Format
run: |
node build_vendor -p mac
if [ ! $(which gcovr) ]; then
brew install gcovr
fi
chmod +x update_baseline.sh
./update_baseline.sh 1
mkdir result
cp -r test/baseline result
chmod +x codeformat.sh
./codeformat.sh
shell: bash

- if: github.event_name == 'pull_request'
name: Run autotest script
- name: Run Autotest
run: |
chmod +x autotest.sh
./autotest.sh
- name: codecov
if: github.event_name == 'pull_request'
uses: codecov/[email protected]
- name: Run Codecov
run: |
chmod +x codecov.sh
./codecov.sh
- name: Upload Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: libpag/result/coverage.xml
- name: The job has failed
file: result/coverage.xml

- name: Save Environment Cache
if: ${{ (github.event_name == 'push') && (steps.environment-cache.outputs.cache-hit != 'true') }}
uses: actions/cache/save@v3
with:
path: |
/usr/local/Cellar/ninja
/usr/local/Cellar/icu4c
/usr/local/bin/ninja
/usr/local/Cellar/yasm
/usr/local/bin/yasm
/usr/local/bin/depsync
/usr/local/lib/node_modules/depsync
/usr/local/Cellar/gcovr
/usr/local/bin/gcovr
/usr/local/Cellar/python-lxml
/usr/local/Cellar/python-markupsafe
/usr/local/lib/python3.12/site-packages/lxml
/usr/local/lib/python3.12/site-packages/markupsafe
key: libpag-environment-autotest-20231029

- name: Save Third-Party Cache
if: ${{ (github.event_name == 'push') && (steps.third-party-cache.outputs.cache-hit != 'true') }}
uses: actions/cache/save@v3
with:
path: |
third_party
test/baseline/.cache
key: third-party-autotest-${{ hashFiles('DEPS') }}-${{ hashFiles('vendor.json') }}-${{ hashFiles('test/baseline/version.json') }}

- name: Job Failed
if: ${{ failure() }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: result
path: result
- uses: actions/upload-artifact@v2

- uses: actions/upload-artifact@v3
with:
name: result
path: result
Loading

0 comments on commit 64f8417

Please sign in to comment.