mirror of
https://github.com/pyTooling/Actions.git
synced 2026-02-12 02:56:56 +08:00
Added PowerShell code.
This commit is contained in:
15
.github/workflows/UnitTesting.yml
vendored
15
.github/workflows/UnitTesting.yml
vendored
@@ -64,16 +64,16 @@ jobs:
|
|||||||
- name: ⏬ Checkout repository
|
- name: ⏬ Checkout repository
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- if: matrix.system == 'msys2'
|
- name: '🟦 Setup MSYS2'
|
||||||
name: '🟦 Setup MSYS2'
|
if: matrix.system == 'msys2'
|
||||||
uses: msys2/setup-msys2@v2
|
uses: msys2/setup-msys2@v2
|
||||||
with:
|
with:
|
||||||
msystem: MINGW64
|
msystem: MINGW64
|
||||||
update: true
|
update: true
|
||||||
pacboy: python-pip:p
|
pacboy: python-pip:p
|
||||||
|
|
||||||
- if: matrix.system != 'msys2'
|
- name: 🐍 Setup Python ${{ matrix.python }}
|
||||||
name: 🐍 Setup Python ${{ matrix.python }}
|
if: matrix.system != 'msys2'
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v2
|
||||||
with:
|
with:
|
||||||
python-version: ${{ matrix.python }}
|
python-version: ${{ matrix.python }}
|
||||||
@@ -84,6 +84,13 @@ jobs:
|
|||||||
python -m pip install ${{ inputs.requirements }}
|
python -m pip install ${{ inputs.requirements }}
|
||||||
|
|
||||||
- name: ☑ Run unit tests
|
- name: ☑ Run unit tests
|
||||||
|
if: matrix.system == 'windows'
|
||||||
|
run: |
|
||||||
|
$PYTEST_ARGS = if (${{ inputs.artifact }} -eq "") { '--junitxml=TestReport.xml' } else { '' }
|
||||||
|
python -m pytest -rA ${{ inputs.unittest_directory }} $PYTEST_ARGS --color=yes
|
||||||
|
|
||||||
|
- name: ☑ Run unit tests
|
||||||
|
if: matrix.system != 'windows'
|
||||||
run: |
|
run: |
|
||||||
[ 'x${{ inputs.artifact }}' != 'x' ] && PYTEST_ARGS='--junitxml=TestReport.xml' || unset PYTEST_ARGS
|
[ 'x${{ inputs.artifact }}' != 'x' ] && PYTEST_ARGS='--junitxml=TestReport.xml' || unset PYTEST_ARGS
|
||||||
python -m pytest -rA ${{ inputs.unittest_directory }} $PYTEST_ARGS --color=yes
|
python -m pytest -rA ${{ inputs.unittest_directory }} $PYTEST_ARGS --color=yes
|
||||||
|
|||||||
Reference in New Issue
Block a user