diff options
Diffstat (limited to 'libs/plugin_python/.github/workflows')
| -rw-r--r-- | libs/plugin_python/.github/workflows/build-and-test.yml | 38 | ||||
| -rw-r--r-- | libs/plugin_python/.github/workflows/linting.yml | 24 |
2 files changed, 62 insertions, 0 deletions
diff --git a/libs/plugin_python/.github/workflows/build-and-test.yml b/libs/plugin_python/.github/workflows/build-and-test.yml new file mode 100644 index 0000000..57e7475 --- /dev/null +++ b/libs/plugin_python/.github/workflows/build-and-test.yml @@ -0,0 +1,38 @@ +name: Build & Test Plugin Python + +on: + push: + branches: [master] + pull_request: + types: [opened, synchronize, reopened] + +env: + VCPKG_BINARY_SOURCES: ${{ vars.AZ_BLOB_VCPKG_URL != '' && format('clear;x-azblob,{0},{1},readwrite', vars.AZ_BLOB_VCPKG_URL, secrets.AZ_BLOB_SAS) || '' }} + +jobs: + build: + runs-on: windows-2022 + steps: + - uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Configure Plugin Python + id: configure-plugin-python + uses: ModOrganizer2/build-with-mob-action@master + with: + mo2-dependencies: uibase + mo2-skip-build: true + + - name: Build Plugin Python + working-directory: ${{ steps.configure-plugin-python.outputs.working-directory }} + run: cmake --build vsbuild --config RelWithDebInfo --verbose ` + --target python-tests --target runner-tests --target proxy + + - name: Test Plugin Python + working-directory: ${{ steps.configure-plugin-python.outputs.working-directory }} + run: ctest --test-dir vsbuild -C RelWithDebInfo --output-on-failure + + - name: Install Plugin Python + working-directory: ${{ steps.configure-plugin-python.outputs.working-directory }} + run: cmake --build vsbuild --config RelWithDebInfo --target INSTALL diff --git a/libs/plugin_python/.github/workflows/linting.yml b/libs/plugin_python/.github/workflows/linting.yml new file mode 100644 index 0000000..70b5bca --- /dev/null +++ b/libs/plugin_python/.github/workflows/linting.yml @@ -0,0 +1,24 @@ +name: Lint Plugin Python + +on: + push: + pull_request: + types: [opened, synchronize, reopened] + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Check format + uses: ModOrganizer2/check-formatting-action@master + with: + check-path: "." + - uses: actions/setup-python@v4 + with: + python-version: "3.12" + - uses: abatilo/actions-poetry@v2 + - name: Check format Python tests + run: | + poetry install --no-root + poetry run poe lint |
