Skip to content

Commit

Permalink
ci: Upload failed MacVim tests artifacts, misc improvements
Browse files Browse the repository at this point in the history
Add new step to upload MacVim test results when we have failed tests.
The xcresult folder can be opened in Xcode for inspection to help
understand what went wrong. Also, fix the ordering so failed Vim GUI
test artifacts can be uploaded as well.

When configuring Vim, be explicit to not build with sodium/gettext for
the non-publish builds. This makes sure that even if the CI environment
somehow has them installed by default, we won't use them by mistake.
Those installed packages would be built for a different OS target anyway
and throw out warnings (the ones we bundle with MacVim are custom built
to target the proper OS versions).
  • Loading branch information
ychin committed Jan 7, 2025
1 parent a6d07ee commit 5b30e66
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/actions/test_macvim_artifacts/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# This is a clone of test_artifacts for MacVim-specific files
name: 'test_macvim_artifacts'
description: "Upload failed MacVim test artifacts"
runs:
using: "composite"
steps:
- name: Upload failed tests
uses: actions/upload-artifact@v4
with:
# Name of the artifact to upload.
name: ${{ github.workflow }}-${{ github.job }}-${{ join(matrix.*, '-') }}-failed-macvim-tests

# A file, directory or wildcard pattern that describes what
# to upload.
path: |
/Users/runner/Library/Developer/Xcode/DerivedData/MacVim-*/Logs/Test/*.xcresult
# The desired behavior if no files are found using the
# provided path.
if-no-files-found: ignore

# Duration after which artifact will expire in days. 0 means
# using repository settings.
retention-days: 0

# If true, an artifact with a matching name will be deleted
overwrite: true
5 changes: 5 additions & 0 deletions .github/workflows/ci-macvim.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,7 @@ jobs:
else
CONFOPT+=(
--disable-sparkle # Disable Sparkle for testing that this flag builds and works
--enable-nls=no --enable-libsodium=no # Disable gettext and libsodium unless we built them ourselves for publish
)
fi
if ${{ matrix.legacy == true }}; then
Expand Down Expand Up @@ -354,6 +355,10 @@ jobs:
run: |
make ${MAKE_BUILD_ARGS} -C src macvim-tests
- name: Upload failed MacVim test results
if: ${{ !cancelled() && failure() }}
uses: ./.github/actions/test_macvim_artifacts

- name: Build Vim test binaries
run: |
# Build the unit test binaries first. With link-time-optimization they take some time to link. Running them
Expand Down

0 comments on commit 5b30e66

Please sign in to comment.