Skip to content

Commit 1698fb4

Browse files
committed
feat: 添加用于运行慢速测试的 npm 脚本
添加 'test:slow' 脚本以专门运行标记为 'Slow' 的 Pester 测试,方便隔离执行耗时较长的测试用例。
1 parent 781fa8b commit 1698fb4

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"test:debug": "pwsh -NoProfile -Command \"\\$env:PWSH_TEST_MODE='debug'; Invoke-Pester -Configuration ( ./PesterConfiguration.ps1 )\"",
2828
"test:serial:debug": "pwsh -NoProfile -Command \"\\$env:PWSH_TEST_MODE='serial'; \\$env:PWSH_TEST_VERBOSE='1'; Invoke-Pester -Configuration ( ./PesterConfiguration.ps1 )\"",
2929
"test:profile": "pwsh -NoProfile -Command \"\\$env:PWSH_TEST_MODE='serial'; \\$env:PWSH_TEST_PATH='./tests/ProfileMode.Tests.ps1'; \\$env:PWSH_TEST_VERBOSE='1'; Invoke-Pester -Configuration ( ./PesterConfiguration.ps1 )\"",
30+
"test:slow": "pwsh -NoProfile -Command \"\\$c = ./PesterConfiguration.ps1; \\$c.Filter.Tag = 'Slow'; \\$c.Filter.ExcludeTag = @(); Invoke-Pester -Configuration \\$c\"",
3031
"test:detailed": "pwsh -Command \"Invoke-Pester -Output Detailed\"",
3132
"scripts:install": "pwsh -File ./install.ps1",
3233
"scoop:update": "scoop update -a",

0 commit comments

Comments
 (0)