When changing build/test/configuration files, ensure they are (1) platform-correct and (2) production-safe.
Apply this standard: 1) Platform-correct environment/config updates
PSModulePath), use the platform’s path separator rather than hard-coding : or ;.2) Gate/disable debug output in production
debug: true (or equivalent flags like --debug) in configs used to generate production artifacts. If needed, enable it only for non-production builds (or via a parameter/flag), because debug output can increase generated code size and noise.Example (pattern):
# Prefer parameters/env gating for debug
steps:
- powershell: |
Install-Module -Name Pester -RequiredVersion 4.10.1 -Force
$sep = [System.IO.Path]::PathSeparator
$env:PSModulePath = $env:PSModulePath + $sep + (pwd).Path
condition: eq('${{ parameters.testTarget }}', 'Test')
continueOnError: true
# In autorest/tspconfig.yaml-like configs: keep debug off unless explicitly requested
options:
"@azure-tools/typespec-powershell":
debug: false
Checklist before merging: