mirror of
https://github.com/tw93/Mole.git
synced 2026-03-23 22:05:07 +00:00
fix(windows): restore complete visual defaults
This commit is contained in:
@@ -37,6 +37,20 @@ Describe "Clean Command" {
|
||||
# If we got here without exception, test passes
|
||||
$true | Should -Be $true
|
||||
}
|
||||
|
||||
It "Should not throw missing Solid property errors during dry-run startup" {
|
||||
$job = Start-Job -ScriptBlock {
|
||||
param($binDir)
|
||||
& powershell -ExecutionPolicy Bypass -File "$binDir\clean.ps1" -DryRun 2>&1
|
||||
} -ArgumentList $script:BinDir
|
||||
|
||||
Start-Sleep -Seconds 3
|
||||
$output = (Receive-Job $job -Keep 2>&1 | Out-String)
|
||||
Stop-Job $job -ErrorAction SilentlyContinue
|
||||
Remove-Job $job -Force -ErrorAction SilentlyContinue
|
||||
|
||||
$output | Should -Not -Match "property 'Solid' cannot be found|找不到属性.?Solid"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -163,6 +177,20 @@ Describe "Main Entry Point" {
|
||||
$result | Should -Not -BeNullOrEmpty
|
||||
$result -join "`n" | Should -Match "Mole|v\d+\.\d+"
|
||||
}
|
||||
|
||||
It "Should not throw missing Solid property errors during menu startup" {
|
||||
$job = Start-Job -ScriptBlock {
|
||||
param($molePath)
|
||||
& powershell -ExecutionPolicy Bypass -File $molePath 2>&1
|
||||
} -ArgumentList $script:MolePath
|
||||
|
||||
Start-Sleep -Seconds 3
|
||||
$output = (Receive-Job $job -Keep 2>&1 | Out-String)
|
||||
Stop-Job $job -ErrorAction SilentlyContinue
|
||||
Remove-Job $job -Force -ErrorAction SilentlyContinue
|
||||
|
||||
$output | Should -Not -Match "property 'Solid' cannot be found|找不到属性.?Solid"
|
||||
}
|
||||
|
||||
It "Should list available commands in help" {
|
||||
$result = & powershell -ExecutionPolicy Bypass -File $script:MolePath -ShowHelp 2>&1
|
||||
|
||||
@@ -31,6 +31,9 @@ Describe "Base Module" {
|
||||
$script:Icons.Success | Should -Not -BeNullOrEmpty
|
||||
$script:Icons.Error | Should -Not -BeNullOrEmpty
|
||||
$script:Icons.Warning | Should -Not -BeNullOrEmpty
|
||||
$script:Icons.Solid | Should -Not -BeNullOrEmpty
|
||||
$script:Icons.Admin | Should -Not -BeNullOrEmpty
|
||||
$script:Icons.Trash | Should -Not -BeNullOrEmpty
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user