Files
runner-images/images/linux/scripts/tests/Node.Tests.ps1
T

19 lines
567 B
PowerShell
Raw Normal View History

2021-02-26 20:06:24 +05:00
Describe "Node.js" {
$binaries = @("node")
$module_commands = (Get-ToolsetContent).node_modules | ForEach-Object { $_.command }
$testCases = $binaries + $module_commands | ForEach-Object { @{NodeCommand = $_} }
It "<NodeCommand>" -TestCases $testCases {
param (
[string] $NodeCommand
)
"$NodeCommand --version" | Should -ReturnZeroExitCode
}
2021-10-30 14:56:36 +03:00
It "Node.js version should correspond to the version in the toolset" {
node --version | Should -BeLike "v$((Get-ToolsetContent).node.default).*"
}
2021-02-26 20:06:24 +05:00
}