build(deps): bump docker/build-push-action from 6.7.0 to 6.9.0 #42
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run UI Tests | |
on: | |
workflow_dispatch: | |
inputs: | |
edgar_renderer_ref: | |
description: 'Arelle/EdgarRenderer branch, tag or SHA to checkout (blank for default)' | |
required: false | |
type: string | |
ixbrl_viewer_ref: | |
description: 'Workiva/ixbrl-viewer branch, tag or SHA to checkout (blank for default)' | |
required: false | |
type: string | |
node_version: | |
default: '19' | |
description: 'Node.js version to use' | |
required: false | |
type: string | |
python_version: | |
default: '3.11' | |
description: 'Python version to use' | |
required: false | |
type: string | |
xule_ref: | |
description: 'xbrlus/xule branch, tag or SHA to checkout (blank for default)' | |
required: false | |
type: string | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build-windows-dispatch: | |
if: github.event_name == 'workflow_dispatch' | |
uses: ./.github/workflows/build-windows.yml | |
with: | |
edgar_renderer_ref: ${{ inputs.edgar_renderer_ref }} | |
ixbrl_viewer_ref: ${{ inputs.ixbrl_viewer_ref }} | |
node_version: ${{ inputs.node_version }} | |
python_version: ${{ inputs.python_version }} | |
xule_ref: ${{ inputs.xule_ref }} | |
build-windows-pr: | |
if: github.event_name == 'pull_request' | |
uses: ./.github/workflows/build-windows.yml | |
ui-tests: | |
needs: [build-windows-dispatch, build-windows-pr] | |
# https://github.com/actions/runner/issues/491 | |
if: always() && (needs.build-windows-dispatch.result == 'success' || needs.build-windows-pr.result == 'success') && !cancelled() | |
runs-on: windows-2022 | |
strategy: | |
fail-fast: false | |
matrix: | |
build-type: | |
- installer | |
- zip | |
- source | |
env: | |
exe_artifact_versioned_name: ${{ github.event_name == 'pull_request' && needs.build-windows-pr.outputs.exe_artifact_versioned_name || needs.build-windows-dispatch.outputs.exe_artifact_versioned_name }} | |
zip_artifact_versioned_name: ${{ github.event_name == 'pull_request' && needs.build-windows-pr.outputs.zip_artifact_versioned_name || needs.build-windows-dispatch.outputs.zip_artifact_versioned_name }} | |
exe_uploaded_artifact_name: ${{ github.event_name == 'pull_request' && needs.build-windows-pr.outputs.exe_uploaded_artifact_name || needs.build-windows-dispatch.outputs.exe_uploaded_artifact_name }} | |
zip_uploaded_artifact_name: ${{ github.event_name == 'pull_request' && needs.build-windows-pr.outputs.zip_uploaded_artifact_name || needs.build-windows-dispatch.outputs.zip_uploaded_artifact_name }} | |
steps: | |
- name: Checkout arelle | |
uses: actions/[email protected] | |
with: | |
fetch-depth: 0 | |
- name: Download installer artifact | |
if: matrix.build-type == 'installer' | |
uses: actions/[email protected] | |
with: | |
name: ${{ env.exe_uploaded_artifact_name }} | |
- name: Download ZIP artifact | |
if: matrix.build-type == 'zip' | |
uses: actions/[email protected] | |
with: | |
name: ${{ env.zip_uploaded_artifact_name }} | |
- name: Install Arelle | |
if: matrix.build-type == 'installer' | |
run: start-process ${{ env.exe_artifact_versioned_name }} -argumentlist /S -nonewwindow -wait | |
- name: Extract artifact | |
if: matrix.build-type == 'zip' | |
run: expand-archive ${{ env.zip_artifact_versioned_name }} build | |
- name: Install Python | |
if: matrix.build-type == 'source' | |
uses: actions/[email protected] | |
with: | |
cache: 'pip' | |
check-latest: true | |
python-version: ${{ github.event_name == 'workflow_dispatch' && inputs.python_version || '3.11' }} | |
- name: Install Python dependencies | |
if: matrix.build-type == 'source' | |
run: | | |
python -m pip install --upgrade pip setuptools wheel | |
pip install -r requirements.txt | |
- name: Install runner | |
run: nuget install NUnit.ConsoleRunner | |
- name: Build tests | |
env: | |
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | |
run: dotnet build tests\integration_tests\ui_tests\ArelleGUITest\ArelleGUITest.sln | |
- name: Set build path | |
run: echo "BUILD_PATH=$((gi tests\integration_tests\ui_tests\ArelleGUITest\ArelleGUITest\bin\Debug\*).FullName)" >> $env:GITHUB_ENV | |
- name: Run tests | |
if: matrix.build-type == 'installer' || matrix.build-type == 'zip' | |
env: | |
ARELLE_USE_BUILD: 'true' | |
ARELLE_PATH: ${{ matrix.build-type == 'zip' && format('{0}/build', github.workspace) || '' }} | |
ARELLE_RESOURCES_PATH: ${{ github.workspace }}\tests\integration_tests\ui_tests\resources | |
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | |
run: dotnet test ${{ env.BUILD_PATH }}\ArelleGUITest.dll --test-adapter-path:(gi .\NUnit.ConsoleRunner*\tools\nunit3-console.exe).FullName | |
- name: Run tests | |
if: matrix.build-type == 'source' | |
env: | |
ARELLE_PATH: ${{ github.workspace }} | |
ARELLE_RESOURCES_PATH: ${{ github.workspace }}\tests\integration_tests\ui_tests\resources | |
ARELLE_PYTHON_EXE: python | |
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | |
run: dotnet test ${{ env.BUILD_PATH }}\ArelleGUITest.dll --test-adapter-path:(gi .\NUnit.ConsoleRunner*\tools\nunit3-console.exe).FullName | |
- name: Upload logs | |
if: always() | |
uses: actions/[email protected] | |
with: | |
name: logs-${{ matrix.build-type }} | |
path: 'c:\temp\testsmedia\*.txt' | |
- name: Upload screenshots | |
# screenshots are only taken on test failure | |
if: failure() | |
uses: actions/[email protected] | |
with: | |
name: screenshots-${{ matrix.build-type }} | |
path: 'c:\temp\testsmedia\*.png' | |
- name: Upload videos | |
# videos are only saved on test failure | |
if: failure() | |
uses: actions/[email protected] | |
with: | |
name: videos-${{ matrix.build-type }} | |
path: 'c:\temp\testsmedia\*.avi' |