diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 632ca792..d91ad5ae 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -14,14 +14,15 @@ jobs: with: run: make test-src - module: + module_tests: name: "Module Unittests" runs-on: ubuntu-latest - container: docker.io/library/python:3.7 steps: - - name: Clone repository - uses: actions/checkout@v2 - - name: Run Module Unittests + - name: "Clone Repository" + uses: actions/checkout@v2 + - name: "Run Module Unittests" + uses: osbuild/containers/ghci/actions/ghci-osbuild@ghci/v1 + with: run: make test-module documentation: @@ -54,26 +55,6 @@ jobs: test -d docs test -f docs/osbuild.1 - unit_tests: - name: "unit" - runs-on: ubuntu-latest - container: - image: docker.io/library/python:3.7 - options: --privileged # Needed for bind mounts in unit tests - steps: - - name: Clone repository - uses: actions/checkout@v2 - with: - path: osbuild - - - name: Install Dependencies - run: pip install jsonschema - - - name: Run test_osbuild - run: | - cd osbuild - python3 -m unittest -v test.test_osbuild - sample_validation: name: "sample validation" runs-on: ubuntu-latest diff --git a/test/test_osbuild.py b/test/mod/test_osbuild.py similarity index 99% rename from test/test_osbuild.py rename to test/mod/test_osbuild.py index 56a5fb01..daaf03b4 100644 --- a/test/test_osbuild.py +++ b/test/mod/test_osbuild.py @@ -1,3 +1,7 @@ +# +# Basic tests for a collection of osbuild modules. +# + import json import os import unittest @@ -224,7 +228,3 @@ class TestDescriptions(unittest.TestCase): self.assertEqual(len(lst), 1) # missing "filename" lst = res[".pipeline.assembler.options.compression"] self.assertEqual(len(lst), 1) # wrong compression method - - -if __name__ == "__main__": - unittest.main()