Skip to content

Commit

Permalink
github: Run openomf with null renderer and audio backends
Browse files Browse the repository at this point in the history
  • Loading branch information
mrannanj committed Dec 2, 2024
1 parent 6add65e commit 211a5db
Show file tree
Hide file tree
Showing 6 changed files with 194 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/compilation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,43 @@ jobs:
cd build-test
ctest --verbose --output-on-failure
- name: Restore omf2097-assets.zip
id: cache-assets
uses: actions/cache/restore@v4
with:
path: omf2097-assets.zip
key: omf2097-assets.zip

- name: Download omf 2097 assets
if: steps.cache-assets.outputs.cache-hit != 'true'
run: wget -q "${{ env.OPENOMF_ASSETS_URL }}"

- name: Cache omf2097-assets.zip
if: steps.cache-assets.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: omf2097-assets.zip
key: omf2097-assets.zip

- name: Extract omf 2097 assets
run: unzip -j omf2097-assets.zip -d build-test/resources

- name: Install pytest requirements
run: |
pipx install poetry
cd pytest
poetry install
#- name: Run pytest tests
# run: pytest -v pytest

- name: Run openomf with null output
run: |
cd build-test
echo "quit" | ./Debug/openomf --force-renderer NULL --force-audio-backend NULL
env:
LSAN_OPTIONS: suppressions=../lsan.supp

# Build windows release artifacts with MSVC
# -----------------------------------------------------------------------------------------------
build_msvc:
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,5 @@ cmake-build-debug/
cmake-build-release/
.cache
compile_commands.json
__pycache__
*.pyc
5 changes: 5 additions & 0 deletions lsan.supp
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# libconfuse
leak:libconfuse

# SDL leak
leak:has_gl_available
131 changes: 131 additions & 0 deletions pytest/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions pytest/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[tool.poetry]
package-mode = false

[tool.poetry.dependencies]
python = "^3.10"
pytest = "^8.3"


[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
8 changes: 8 additions & 0 deletions pytest/test_menus.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import pytest
import subprocess

# FIXME: paths, input, fixture, etc
def test_ok():
print(subprocess.run(["./openomf", "--force-renderer", "NULL",
"--force-audio-backend", "NULL"], cwd="build",
timeout=20))

0 comments on commit 211a5db

Please sign in to comment.