Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run internal tests in Cygwin #1592

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -320,3 +320,40 @@ jobs:
shell: bash
run: |
test/run-tests.sh

cygwin:
strategy:
matrix:
bits: [32, 64]
include:
- bits: 32
arch: x86
- bits: 64
arch: x86_64
fail-fast: false
runs-on: windows-2019
timeout-minutes: 30
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Cygwin
uses: cygwin/cygwin-install-action@v4
with:
platform: ${{ matrix.arch }}
packages: >-
bison
gcc-g++
libpng-devel
make
pkg-config
- name: Build & install using Make
shell: C:\cygwin\bin\bash.exe '{0}'
run: | # Cygwin does not support `make develop` sanitizers ASan or UBSan
PATH="/usr/bin:$(cygpath "${SYSTEMROOT}")/System32"
Rangi42 marked this conversation as resolved.
Show resolved Hide resolved
make -kj Q=
make install -j Q=
- name: Run tests
shell: C:\cygwin\bin\bash.exe '{0}'
run: |
PATH="/usr/bin:$(cygpath "${SYSTEMROOT}")/System32"
test/run-tests.sh --only-internal
13 changes: 11 additions & 2 deletions test/run-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ cd "$(dirname "$0")"
usage() {
echo "Runs regression tests on RGBDS."
echo "Options:"
echo " -h, --help show this help message"
echo " --only-free skip tests that build nonfree codebases"
echo " -h, --help show this help message"
echo " --only-free skip tests that build nonfree codebases"
echo " --only-internal skip tests that build external codebases"
}

# Parse options in pure Bash because macOS `getopt` is stuck
# in what util-linux `getopt` calls `GETOPT_COMPATIBLE` mode
nonfree=true
external=true
FETCH_TEST_DEPS="fetch-test-deps.sh"
while [[ $# -gt 0 ]]; do
case "$1" in
Expand All @@ -24,6 +26,9 @@ while [[ $# -gt 0 ]]; do
nonfree=false
FETCH_TEST_DEPS="fetch-test-deps.sh --only-free"
;;
--only-internal)
external=false
;;
--)
break
;;
Expand All @@ -49,6 +54,10 @@ for dir in asm link fix gfx; do
popd
done

if ! "$external"; then
exit
fi

# Test some significant external projects that use RGBDS
# When adding new ones, don't forget to add them to the .gitignore!
# When updating subprojects, change the commit being checked out, and set the `shallow-since`
Expand Down
Loading