parameters: - name: nodeVersion type: string default: '' - name: npm_config_cache type: string default: '' - name: PlaywrightUserEmail type: string default: '' - name: PlaywrightPassword type: string default: '' - name: ASPNETCORE_URLS type: string default: '' steps: - task: NodeTool@0 displayName: Use Node.js $(nodeVersion) inputs: versionSpec: $(nodeVersion) - pwsh: | "UMBRACO_USER_LOGIN=${{ parameters.PlaywrightUserEmail }} UMBRACO_USER_PASSWORD=${{ parameters.PlaywrightPassword }} URL=${{ parameters.ASPNETCORE_URLS }} STORAGE_STAGE_PATH=$(Build.SourcesDirectory)/tests/Umbraco.Tests.AcceptanceTest/playwright/.auth/user.json CONSOLE_ERRORS_PATH=$(Build.SourcesDirectory)/tests/Umbraco.Tests.AcceptanceTest/console-errors.json" | Out-File .env displayName: Generate .env workingDirectory: $(Build.SourcesDirectory)/tests/Umbraco.Tests.AcceptanceTest # Cache and restore NPM packages - task: Cache@2 displayName: Cache NPM packages inputs: key: 'npm_e2e | "$(Agent.OS)" | $(Build.SourcesDirectory)/tests/Umbraco.Tests.AcceptanceTest/package-lock.json' restoreKeys: | npm_e2e | "$(Agent.OS)" npm_e2e path: ${{ parameters.npm_config_cache }} - script: npm ci --no-fund --no-audit --prefer-offline workingDirectory: $(Build.SourcesDirectory)/tests/Umbraco.Tests.AcceptanceTest displayName: Restore NPM packages