mirror of
				https://github.com/onyx-and-iris/voicemeeter-api-powershell.git
				synced 2025-10-30 20:31:45 +00:00 
			
		
		
		
	auto login added, tests updated to take $true, $false
Added $this.Login() into Remote constructor to automatically log user in. Updated test codes accordingly. Boolean params take $true and $false Updated readme to reflect changes.
This commit is contained in:
		
							parent
							
								
									ffc46fae94
								
							
						
					
					
						commit
						8a3b8da635
					
				
							
								
								
									
										19
									
								
								example.ps1
									
									
									
									
									
								
							
							
						
						
									
										19
									
								
								example.ps1
									
									
									
									
									
								
							| @ -3,24 +3,19 @@ | |||||||
| try { | try { | ||||||
|     $vmr = [Remote]::new('potato') |     $vmr = [Remote]::new('potato') | ||||||
| 
 | 
 | ||||||
|     $vmr.Login() |     $vmr.button[0].state = $true | ||||||
| 
 |  | ||||||
|     $vmr.button[0].state = 1 |  | ||||||
|     $vmr.button[0].state |     $vmr.button[0].state | ||||||
|     $vmr.button[0].state = 0 |     $vmr.button[0].state = $false | ||||||
|     $vmr.button[0].state |     $vmr.button[0].state | ||||||
| 
 | 
 | ||||||
|     $vmr.strip[0].mono = 1 |     $vmr.strip[0].mono = $true | ||||||
|     $vmr.strip[0].mono |     $vmr.strip[0].mono | ||||||
|     $vmr.strip[0].mono = 0 |     $vmr.strip[0].mono = $false | ||||||
|     $vmr.strip[0].mono |     $vmr.strip[0].mono | ||||||
| 
 | 
 | ||||||
|     $vmr.bus[2].mute = 1 |     $vmr.bus[2].mute = $true | ||||||
|     $vmr.bus[2].mute |     $vmr.bus[2].mute | ||||||
|     $vmr.bus[2].mute = 0 |     $vmr.bus[2].mute = $false | ||||||
|     $vmr.bus[2].mute |     $vmr.bus[2].mute | ||||||
| } | } | ||||||
| finally | finally { $vmr.Logout() } | ||||||
| { |  | ||||||
|     $vmr.Logout() |  | ||||||
| } |  | ||||||
|  | |||||||
							
								
								
									
										19
									
								
								lib/base.ps1
									
									
									
									
									
								
							
							
						
						
									
										19
									
								
								lib/base.ps1
									
									
									
									
									
								
							| @ -52,11 +52,12 @@ Function Param_Set_Multi { | |||||||
|         $line = $($line -replace '\s+', ' ') |         $line = $($line -replace '\s+', ' ') | ||||||
|         $line = $line.TrimEnd() |         $line = $line.TrimEnd() | ||||||
|         $line = $line -replace '\s', '=' |         $line = $line -replace '\s', '=' | ||||||
|  |         $line = $line -replace 'True', '1' | ||||||
|  |         $line = $line -replace 'False', '0' | ||||||
| 
 | 
 | ||||||
|         $cmd += $line + ';' |         $cmd += $line + ';' | ||||||
|     } |     } | ||||||
|     [String]$cmd = $cmd.SubString(1) |     [String]$cmd = $cmd.SubString(1) | ||||||
|     Write-Host $cmd |  | ||||||
| 
 | 
 | ||||||
|     $retval = $lib::VBVMR_SetParameters($cmd) |     $retval = $lib::VBVMR_SetParameters($cmd) | ||||||
|     if($retval) { Throw "ERROR: CAPI return value: $retval" } |     if($retval) { Throw "ERROR: CAPI return value: $retval" } | ||||||
| @ -219,23 +220,23 @@ if ($MyInvocation.InvocationName -ne '.') | |||||||
|     Login |     Login | ||||||
| 
 | 
 | ||||||
|     $hash = @{ |     $hash = @{ | ||||||
|         "Strip[0].Mute" = 1 |         "Strip[0].Mute" = $true | ||||||
|         "Strip[1].Mute" = 1 |         "Strip[1].Mute" = $true | ||||||
|         "Strip[2].Mute" = 1 |         "Strip[2].Mute" = $true | ||||||
|         "Strip[0].Mono" = 1 |         "Strip[0].Mono" = $true | ||||||
|         "Strip[1].Mono" = 1 |         "Strip[1].Mono" = $true | ||||||
|         "Strip[2].Mono" = 1 |         "Strip[2].Mono" = $true | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|     0..10 | ForEach-Object { |     0..10 | ForEach-Object { | ||||||
|         foreach($key in $($hash.keys)){ |         foreach($key in $($hash.keys)){ | ||||||
|         $hash[$key] = 1 |         $hash[$key] = $true | ||||||
|         } |         } | ||||||
|         Param_Set_Multi -HASH $hash |         Param_Set_Multi -HASH $hash | ||||||
| 
 | 
 | ||||||
|         foreach($key in $($hash.keys)){ |         foreach($key in $($hash.keys)){ | ||||||
|         $hash[$key] = 0 |         $hash[$key] = $false | ||||||
|         } |         } | ||||||
|         Param_Set_Multi -HASH $hash |         Param_Set_Multi -HASH $hash | ||||||
|     } |     } | ||||||
|  | |||||||
							
								
								
									
										18
									
								
								lib/bus.ps1
									
									
									
									
									
								
							
							
						
						
									
										18
									
								
								lib/bus.ps1
									
									
									
									
									
								
							| @ -21,11 +21,9 @@ class Bus { | |||||||
| 
 | 
 | ||||||
|     hidden $_mono = $($this | Add-Member ScriptProperty 'mono' ` |     hidden $_mono = $($this | Add-Member ScriptProperty 'mono' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('Mono')) |             $this.Getter($this.cmd('Mono')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._mono = $this.Setter($this.cmd('Mono'), $arg) |             $this._mono = $this.Setter($this.cmd('Mono'), $arg) | ||||||
|         } |         } | ||||||
| @ -33,11 +31,9 @@ class Bus { | |||||||
| 
 | 
 | ||||||
|     hidden $_mute = $($this | Add-Member ScriptProperty 'mute' ` |     hidden $_mute = $($this | Add-Member ScriptProperty 'mute' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('Mute')) |             $this.Getter($this.cmd('Mute')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._mute = $this.Setter($this.cmd('Mute'), $arg) |             $this._mute = $this.Setter($this.cmd('Mute'), $arg) | ||||||
|         } |         } | ||||||
| @ -45,11 +41,9 @@ class Bus { | |||||||
| 
 | 
 | ||||||
|     hidden $_gain = $($this | Add-Member ScriptProperty 'gain' ` |     hidden $_gain = $($this | Add-Member ScriptProperty 'gain' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('gain')) |             $this.Getter($this.cmd('gain')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._gain = $this.Setter($this.cmd('gain'), $arg) |             $this._gain = $this.Setter($this.cmd('gain'), $arg) | ||||||
|         } |         } | ||||||
| @ -67,20 +61,18 @@ Function Buses { | |||||||
| if ($MyInvocation.InvocationName -ne '.') | if ($MyInvocation.InvocationName -ne '.') | ||||||
| { | { | ||||||
|     . .\voicemeeter.ps1 |     . .\voicemeeter.ps1 | ||||||
| 
 |     try { | ||||||
|         $vmr = [Remote]::new('potato') |         $vmr = [Remote]::new('potato') | ||||||
| 
 | 
 | ||||||
|     $vmr.Login() |         $vmr.bus[0].mono = $true | ||||||
| 
 |  | ||||||
|     $vmr.bus[0].mono = 1 |  | ||||||
|         $vmr.bus[0].mono |         $vmr.bus[0].mono | ||||||
|     $vmr.bus[0].mono = 0 |         $vmr.bus[0].mono = $false | ||||||
|         $vmr.bus[0].mono |         $vmr.bus[0].mono | ||||||
| 
 | 
 | ||||||
|         $vmr.bus[1].gain = 3.2 |         $vmr.bus[1].gain = 3.2 | ||||||
|         $vmr.bus[1].gain |         $vmr.bus[1].gain | ||||||
|         $vmr.bus[2].gain = -2.0 |         $vmr.bus[2].gain = -2.0 | ||||||
|         $vmr.bus[2].gain |         $vmr.bus[2].gain | ||||||
| 
 |     } | ||||||
|     $vmr.Logout() |     finally { $vmr.Logout() } | ||||||
| } | } | ||||||
|  | |||||||
| @ -63,17 +63,13 @@ Function Buttons { | |||||||
| if ($MyInvocation.InvocationName -ne '.') | if ($MyInvocation.InvocationName -ne '.') | ||||||
| { | { | ||||||
|     . .\voicemeeter.ps1 |     . .\voicemeeter.ps1 | ||||||
| 
 |     try { | ||||||
|         $vmr = [Remote]::new('potato') |         $vmr = [Remote]::new('potato') | ||||||
| 
 | 
 | ||||||
|     $vmr.Login() |         $vmr.button[0].state = $true | ||||||
| 
 |  | ||||||
|     $vmr.button = Buttons |  | ||||||
| 
 |  | ||||||
|     $vmr.button[0].state = 1 |  | ||||||
|         $vmr.button[0].state |         $vmr.button[0].state | ||||||
|     $vmr.button[0].state = 0 |         $vmr.button[0].state = $false | ||||||
|         $vmr.button[0].state |         $vmr.button[0].state | ||||||
| 
 |     } | ||||||
|     $vmr.Logout() |     finally { $vmr.Logout() } | ||||||
| } | } | ||||||
|  | |||||||
| @ -21,11 +21,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_mono = $($this | Add-Member ScriptProperty 'mono' ` |     hidden $_mono = $($this | Add-Member ScriptProperty 'mono' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('Mono')) |             $this.Getter($this.cmd('Mono')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._mono = $this.Setter($this.cmd('Mono'), $arg) |             $this._mono = $this.Setter($this.cmd('Mono'), $arg) | ||||||
|         } |         } | ||||||
| @ -33,11 +31,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_solo = $($this | Add-Member ScriptProperty 'solo' ` |     hidden $_solo = $($this | Add-Member ScriptProperty 'solo' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('Solo')) |             $this.Getter($this.cmd('Solo')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._solo = $this.Setter($this.cmd('Solo'), $arg) |             $this._solo = $this.Setter($this.cmd('Solo'), $arg) | ||||||
|         } |         } | ||||||
| @ -45,11 +41,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_mute = $($this | Add-Member ScriptProperty 'mute' ` |     hidden $_mute = $($this | Add-Member ScriptProperty 'mute' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('Mute')) |             $this.Getter($this.cmd('Mute')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._mute = $this.Setter($this.cmd('Mute'), $arg) |             $this._mute = $this.Setter($this.cmd('Mute'), $arg) | ||||||
|         } |         } | ||||||
| @ -57,11 +51,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_A1 = $($this | Add-Member ScriptProperty 'A1' ` |     hidden $_A1 = $($this | Add-Member ScriptProperty 'A1' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('A1')) |             $this.Getter($this.cmd('A1')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._A1 = $this.Setter($this.cmd('A1'), $arg) |             $this._A1 = $this.Setter($this.cmd('A1'), $arg) | ||||||
|         } |         } | ||||||
| @ -69,11 +61,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_A2 = $($this | Add-Member ScriptProperty 'A2' ` |     hidden $_A2 = $($this | Add-Member ScriptProperty 'A2' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('A2')) |             $this.Getter($this.cmd('A2')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._A2 = $this.Setter($this.cmd('A2'), $arg) |             $this._A2 = $this.Setter($this.cmd('A2'), $arg) | ||||||
|         } |         } | ||||||
| @ -81,11 +71,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_A3 = $($this | Add-Member ScriptProperty 'A3' ` |     hidden $_A3 = $($this | Add-Member ScriptProperty 'A3' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('A3')) |             $this.Getter($this.cmd('A3')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._A3 = $this.Setter($this.cmd('A3'), $arg) |             $this._A3 = $this.Setter($this.cmd('A3'), $arg) | ||||||
|         } |         } | ||||||
| @ -93,11 +81,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_A4 = $($this | Add-Member ScriptProperty 'A4' ` |     hidden $_A4 = $($this | Add-Member ScriptProperty 'A4' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('A4')) |             $this.Getter($this.cmd('A4')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._A4 = $this.Setter($this.cmd('A4'), $arg) |             $this._A4 = $this.Setter($this.cmd('A4'), $arg) | ||||||
|         } |         } | ||||||
| @ -105,11 +91,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_A5 = $($this | Add-Member ScriptProperty 'A5' ` |     hidden $_A5 = $($this | Add-Member ScriptProperty 'A5' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('A5')) |             $this.Getter($this.cmd('A5')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._A5 = $this.Setter($this.cmd('A5'), $arg) |             $this._A5 = $this.Setter($this.cmd('A5'), $arg) | ||||||
|         } |         } | ||||||
| @ -117,11 +101,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_B1 = $($this | Add-Member ScriptProperty 'B1' ` |     hidden $_B1 = $($this | Add-Member ScriptProperty 'B1' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('B1')) |             $this.Getter($this.cmd('B1')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._B1 = $this.Setter($this.cmd('B1'), $arg) |             $this._B1 = $this.Setter($this.cmd('B1'), $arg) | ||||||
|         } |         } | ||||||
| @ -129,11 +111,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_B2 = $($this | Add-Member ScriptProperty 'B2' ` |     hidden $_B2 = $($this | Add-Member ScriptProperty 'B2' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('B2')) |             $this.Getter($this.cmd('B2')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._B2 = $this.Setter($this.cmd('B2'), $arg) |             $this._B2 = $this.Setter($this.cmd('B2'), $arg) | ||||||
|         } |         } | ||||||
| @ -141,11 +121,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_B3 = $($this | Add-Member ScriptProperty 'B3' ` |     hidden $_B3 = $($this | Add-Member ScriptProperty 'B3' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('B3')) |             $this.Getter($this.cmd('B3')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._B3 = $this.Setter($this.cmd('B3'), $arg) |             $this._B3 = $this.Setter($this.cmd('B3'), $arg) | ||||||
|         } |         } | ||||||
| @ -153,11 +131,9 @@ class Strip { | |||||||
| 
 | 
 | ||||||
|     hidden $_gain = $($this | Add-Member ScriptProperty 'gain' ` |     hidden $_gain = $($this | Add-Member ScriptProperty 'gain' ` | ||||||
|         { |         { | ||||||
|             # get |  | ||||||
|             $this.Getter($this.cmd('gain')) |             $this.Getter($this.cmd('gain')) | ||||||
|         }` |         }` | ||||||
|         { |         { | ||||||
|             # set |  | ||||||
|             param ( [Single]$arg ) |             param ( [Single]$arg ) | ||||||
|             $this._gain = $this.Setter($this.cmd('gain'), $arg) |             $this._gain = $this.Setter($this.cmd('gain'), $arg) | ||||||
|         } |         } | ||||||
| @ -175,14 +151,12 @@ Function Strips { | |||||||
| if ($MyInvocation.InvocationName -ne '.') | if ($MyInvocation.InvocationName -ne '.') | ||||||
| { | { | ||||||
|     . .\voicemeeter.ps1 |     . .\voicemeeter.ps1 | ||||||
| 
 |     try { | ||||||
|         $vmr = [Remote]::new('potato') |         $vmr = [Remote]::new('potato') | ||||||
| 
 | 
 | ||||||
|     $vmr.Login() |         $vmr.strip[1].A1 = $true | ||||||
| 
 |  | ||||||
|     $vmr.strip[1].A1 = 1 |  | ||||||
|         $vmr.strip[1].A1 |         $vmr.strip[1].A1 | ||||||
|     $vmr.strip[2].A2 = 0 |         $vmr.strip[2].A2 = $false | ||||||
|         $vmr.strip[2].A2 |         $vmr.strip[2].A2 | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| @ -190,6 +164,6 @@ if ($MyInvocation.InvocationName -ne '.') | |||||||
|         $vmr.strip[1].gain |         $vmr.strip[1].gain | ||||||
|         $vmr.strip[2].gain = -2.0 |         $vmr.strip[2].gain = -2.0 | ||||||
|         $vmr.strip[2].gain |         $vmr.strip[2].gain | ||||||
| 
 |     } | ||||||
|     $vmr.Logout() |     finally { $vmr.Logout() } | ||||||
| } | } | ||||||
|  | |||||||
| @ -10,6 +10,7 @@ class Remote { | |||||||
|     Remote ([String]$type) |     Remote ([String]$type) | ||||||
|     { |     { | ||||||
|         $this.type = $type |         $this.type = $type | ||||||
|  |         $this.Login() | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     [void] Login () { |     [void] Login () { | ||||||
| @ -24,4 +25,3 @@ class Remote { | |||||||
|         Logout |         Logout | ||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 |  | ||||||
|  | |||||||
| @ -2,97 +2,97 @@ Describe -Tag 'higher', -TestName 'All Alias Tests' { | |||||||
|     Describe 'Macrobutton Tests' { |     Describe 'Macrobutton Tests' { | ||||||
|         Context 'mode = State' { |         Context 'mode = State' { | ||||||
|             It 'Should set macrobutton[0] State to 1' { |             It 'Should set macrobutton[0] State to 1' { | ||||||
|                 $vmr.button[0].state = 1 |                 $vmr.button[0].state = $true | ||||||
|                 $vmr.button[0].state | Should -Be 1 |                 $vmr.button[0].state | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[0] State to 0' { |             It 'Should set macrobutton[0] State to 0' { | ||||||
|                 $vmr.button[0].state = 0 |                 $vmr.button[0].state = $false | ||||||
|                 $vmr.button[0].state | Should -Be 0 |                 $vmr.button[0].state | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] State to 1' { |             It 'Should set macrobutton[1] State to 1' { | ||||||
|                 $vmr.button[1].state = 1 |                 $vmr.button[1].state = $true | ||||||
|                 $vmr.button[1].state | Should -Be 1 |                 $vmr.button[1].state | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] State to 0' { |             It 'Should set macrobutton[1] State to 0' { | ||||||
|                 $vmr.button[1].state = 0 |                 $vmr.button[1].state = $false | ||||||
|                 $vmr.button[1].state | Should -Be 0 |                 $vmr.button[1].state | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] State to 1' { |             It 'Should set macrobutton[2] State to 1' { | ||||||
|                 $vmr.button[2].state = 1 |                 $vmr.button[2].state = $true | ||||||
|                 $vmr.button[2].state | Should -Be 1 |                 $vmr.button[2].state | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] State to 0' { |             It 'Should set macrobutton[2] State to 0' { | ||||||
|                 $vmr.button[2].state = 0 |                 $vmr.button[2].state = $false | ||||||
|                 $vmr.button[2].state | Should -Be 0 |                 $vmr.button[2].state | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'mode = StateOnly' { |         Context 'mode = StateOnly' { | ||||||
|             It 'Should set macrobutton[0] StateOnly to 1' { |             It 'Should set macrobutton[0] StateOnly to 1' { | ||||||
|                 $vmr.button[0].stateonly = 1 |                 $vmr.button[0].stateonly = $true | ||||||
|                 $vmr.button[0].stateonly | Should -Be 1 |                 $vmr.button[0].stateonly | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[0] StateOnly to 0' { |             It 'Should set macrobutton[0] StateOnly to 0' { | ||||||
|                 $vmr.button[0].stateonly = 0 |                 $vmr.button[0].stateonly = $false | ||||||
|                 $vmr.button[0].stateonly | Should -Be 0 |                 $vmr.button[0].stateonly | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] StateOnly to 1' { |             It 'Should set macrobutton[1] StateOnly to 1' { | ||||||
|                 $vmr.button[1].stateonly = 1 |                 $vmr.button[1].stateonly = $true | ||||||
|                 $vmr.button[1].stateonly | Should -Be 1 |                 $vmr.button[1].stateonly | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] StateOnly to 0' { |             It 'Should set macrobutton[1] StateOnly to 0' { | ||||||
|                 $vmr.button[1].stateonly = 0 |                 $vmr.button[1].stateonly = $false | ||||||
|                 $vmr.button[1].stateonly | Should -Be 0 |                 $vmr.button[1].stateonly | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] StateOnly to 1' { |             It 'Should set macrobutton[2] StateOnly to 1' { | ||||||
|                 $vmr.button[2].stateonly = 1 |                 $vmr.button[2].stateonly = $true | ||||||
|                 $vmr.button[2].stateonly | Should -Be 1 |                 $vmr.button[2].stateonly | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] StateOnly to 0' { |             It 'Should set macrobutton[2] StateOnly to 0' { | ||||||
|                 $vmr.button[2].stateonly = 0 |                 $vmr.button[2].stateonly = $false | ||||||
|                 $vmr.button[2].stateonly | Should -Be 0 |                 $vmr.button[2].stateonly | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'mode = Trigger' { |         Context 'mode = Trigger' { | ||||||
|             It 'Should set macrobutton[0] Trigger to 1' { |             It 'Should set macrobutton[0] Trigger to 1' { | ||||||
|                 $vmr.button[0].trigger = 1 |                 $vmr.button[0].trigger = $true | ||||||
|                 $vmr.button[0].trigger | Should -Be 1 |                 $vmr.button[0].trigger | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[0] Trigger to 0' { |             It 'Should set macrobutton[0] Trigger to 0' { | ||||||
|                 $vmr.button[0].trigger = 0 |                 $vmr.button[0].trigger = $false | ||||||
|                 $vmr.button[0].trigger | Should -Be 0 |                 $vmr.button[0].trigger | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] Trigger to 1' { |             It 'Should set macrobutton[1] Trigger to 1' { | ||||||
|                 $vmr.button[1].trigger = 1 |                 $vmr.button[1].trigger = $true | ||||||
|                 $vmr.button[1].trigger | Should -Be 1 |                 $vmr.button[1].trigger | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[1] Trigger to 0' { |             It 'Should set macrobutton[1] Trigger to 0' { | ||||||
|                 $vmr.button[1].trigger = 0 |                 $vmr.button[1].trigger = $false | ||||||
|                 $vmr.button[1].trigger | Should -Be 0 |                 $vmr.button[1].trigger | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] Trigger to 1' { |             It 'Should set macrobutton[2] Trigger to 1' { | ||||||
|                 $vmr.button[2].trigger = 1 |                 $vmr.button[2].trigger = $true | ||||||
|                 $vmr.button[2].trigger | Should -Be 1 |                 $vmr.button[2].trigger | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set macrobutton[2] Trigger to 0' { |             It 'Should set macrobutton[2] Trigger to 0' { | ||||||
|                 $vmr.button[2].trigger = 0 |                 $vmr.button[2].trigger = $false | ||||||
|                 $vmr.button[2].trigger | Should -Be 0 |                 $vmr.button[2].trigger | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
| @ -100,289 +100,289 @@ Describe -Tag 'higher', -TestName 'All Alias Tests' { | |||||||
|     Describe 'Set and Get Param Float Tests' { |     Describe 'Set and Get Param Float Tests' { | ||||||
|         Context 'Strip[i].Mute' { |         Context 'Strip[i].Mute' { | ||||||
|             It 'Should set Strip[0].Mute to 1' { |             It 'Should set Strip[0].Mute to 1' { | ||||||
|                 $vmr.strip[0].mute = 1 |                 $vmr.strip[0].mute = $true | ||||||
|                 $vmr.strip[0].mute | Should -Be 1 |                 $vmr.strip[0].mute | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].Mute to 0' { |             It 'Should set Strip[0].Mute to 0' { | ||||||
|                 $vmr.strip[0].mute = 0 |                 $vmr.strip[0].mute = $false | ||||||
|                 $vmr.strip[0].mute | Should -Be 0 |                 $vmr.strip[0].mute | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Mute to 1' { |             It 'Should set Strip[1].Mute to 1' { | ||||||
|                 $vmr.strip[1].mute = 1 |                 $vmr.strip[1].mute = $true | ||||||
|                 $vmr.strip[1].mute | Should -Be 1 |                 $vmr.strip[1].mute | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Mute to 0' { |             It 'Should set Strip[1].Mute to 0' { | ||||||
|                 $vmr.strip[1].mute = 0 |                 $vmr.strip[1].mute = $false | ||||||
|                 $vmr.strip[1].mute | Should -Be 0 |                 $vmr.strip[1].mute | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Mute to 1' { |             It 'Should set Strip[2].Mute to 1' { | ||||||
|                 $vmr.strip[2].mute = 1 |                 $vmr.strip[2].mute = $true | ||||||
|                 $vmr.strip[2].mute | Should -Be 1 |                 $vmr.strip[2].mute | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Mute to 0' { |             It 'Should set Strip[2].Mute to 0' { | ||||||
|                 $vmr.strip[2].mute = 0 |                 $vmr.strip[2].mute = $false | ||||||
|                 $vmr.strip[2].mute | Should -Be 0 |                 $vmr.strip[2].mute | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].Solo' { |         Context 'Strip[i].Solo' { | ||||||
|             It 'Should set Strip[0].Solo to 1' { |             It 'Should set Strip[0].Solo to 1' { | ||||||
|                 $vmr.strip[0].solo = 1 |                 $vmr.strip[0].solo = $true | ||||||
|                 $vmr.strip[0].solo | Should -Be 1 |                 $vmr.strip[0].solo | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].Solo to 0' { |             It 'Should set Strip[0].Solo to 0' { | ||||||
|                 $vmr.strip[0].solo = 0 |                 $vmr.strip[0].solo = $false | ||||||
|                 $vmr.strip[0].solo | Should -Be 0 |                 $vmr.strip[0].solo | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Solo to 1' { |             It 'Should set Strip[1].Solo to 1' { | ||||||
|                 $vmr.strip[1].solo = 1 |                 $vmr.strip[1].solo = $true | ||||||
|                 $vmr.strip[1].solo | Should -Be 1 |                 $vmr.strip[1].solo | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Solo to 0' { |             It 'Should set Strip[1].Solo to 0' { | ||||||
|                 $vmr.strip[1].solo = 0 |                 $vmr.strip[1].solo = $false | ||||||
|                 $vmr.strip[1].solo | Should -Be 0 |                 $vmr.strip[1].solo | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Solo to 1' { |             It 'Should set Strip[2].Solo to 1' { | ||||||
|                 $vmr.strip[2].solo = 1 |                 $vmr.strip[2].solo = $true | ||||||
|                 $vmr.strip[2].solo | Should -Be 1 |                 $vmr.strip[2].solo | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Solo to 0' { |             It 'Should set Strip[2].Solo to 0' { | ||||||
|                 $vmr.strip[2].solo = 0 |                 $vmr.strip[2].solo = $false | ||||||
|                 $vmr.strip[2].solo | Should -Be 0 |                 $vmr.strip[2].solo | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].Mono' { |         Context 'Strip[i].Mono' { | ||||||
|             It 'Should set Strip[0].Mono to 1' { |             It 'Should set Strip[0].Mono to 1' { | ||||||
|                 $vmr.strip[0].mono = 1 |                 $vmr.strip[0].mono = $true | ||||||
|                 $vmr.strip[0].mono | Should -Be 1 |                 $vmr.strip[0].mono | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].Mono to 0' { |             It 'Should set Strip[0].Mono to 0' { | ||||||
|                 $vmr.strip[0].mono = 0 |                 $vmr.strip[0].mono = $false | ||||||
|                 $vmr.strip[0].mono | Should -Be 0 |                 $vmr.strip[0].mono | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Mono to 1' { |             It 'Should set Strip[1].Mono to 1' { | ||||||
|                 $vmr.strip[1].mono = 1 |                 $vmr.strip[1].mono = $true | ||||||
|                 $vmr.strip[1].mono | Should -Be 1 |                 $vmr.strip[1].mono | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].Mono to 0' { |             It 'Should set Strip[1].Mono to 0' { | ||||||
|                 $vmr.strip[1].mono = 0 |                 $vmr.strip[1].mono = $false | ||||||
|                 $vmr.strip[1].mono | Should -Be 0 |                 $vmr.strip[1].mono | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Mono to 1' { |             It 'Should set Strip[2].Mono to 1' { | ||||||
|                 $vmr.strip[2].mono = 1 |                 $vmr.strip[2].mono = $true | ||||||
|                 $vmr.strip[2].mono | Should -Be 1 |                 $vmr.strip[2].mono | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].Mono to 0' { |             It 'Should set Strip[2].Mono to 0' { | ||||||
|                 $vmr.strip[2].mono = 0 |                 $vmr.strip[2].mono = $false | ||||||
|                 $vmr.strip[2].mono | Should -Be 0 |                 $vmr.strip[2].mono | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].A1' { |         Context 'Strip[i].A1' { | ||||||
|             It 'Should set Strip[0].A1 to 1' { |             It 'Should set Strip[0].A1 to 1' { | ||||||
|                 $vmr.strip[0].A1 = 1 |                 $vmr.strip[0].A1 = $true | ||||||
|                 $vmr.strip[0].A1 | Should -Be 1 |                 $vmr.strip[0].A1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].A1 to 0' { |             It 'Should set Strip[0].A1 to 0' { | ||||||
|                 $vmr.strip[0].A1 = 0 |                 $vmr.strip[0].A1 = $false | ||||||
|                 $vmr.strip[0].A1 | Should -Be 0 |                 $vmr.strip[0].A1 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A1 to 1' { |             It 'Should set Strip[1].A1 to 1' { | ||||||
|                 $vmr.strip[1].A1 = 1 |                 $vmr.strip[1].A1 = $true | ||||||
|                 $vmr.strip[1].A1 | Should -Be 1 |                 $vmr.strip[1].A1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A1 to 0' { |             It 'Should set Strip[1].A1 to 0' { | ||||||
|                 $vmr.strip[1].A1 = 0 |                 $vmr.strip[1].A1 = $false | ||||||
|                 $vmr.strip[1].A1 | Should -Be 0 |                 $vmr.strip[1].A1 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A1 to 1' { |             It 'Should set Strip[2].A1 to 1' { | ||||||
|                 $vmr.strip[2].A1 = 1 |                 $vmr.strip[2].A1 = $true | ||||||
|                 $vmr.strip[2].A1 | Should -Be 1 |                 $vmr.strip[2].A1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A1 to 0' { |             It 'Should set Strip[2].A1 to 0' { | ||||||
|                 $vmr.strip[2].A1 = 0 |                 $vmr.strip[2].A1 = $false | ||||||
|                 $vmr.strip[2].A1 | Should -Be 0 |                 $vmr.strip[2].A1 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].A2' { |         Context 'Strip[i].A2' { | ||||||
|             It 'Should set Strip[0].A2 to 1' { |             It 'Should set Strip[0].A2 to 1' { | ||||||
|                 $vmr.strip[0].A2 = 1 |                 $vmr.strip[0].A2 = $true | ||||||
|                 $vmr.strip[0].A2 | Should -Be 1 |                 $vmr.strip[0].A2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].v to 0' { |             It 'Should set Strip[0].v to 0' { | ||||||
|                 $vmr.strip[0].A2 = 0 |                 $vmr.strip[0].A2 = $false | ||||||
|                 $vmr.strip[0].A2 | Should -Be 0 |                 $vmr.strip[0].A2 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A2 to 1' { |             It 'Should set Strip[1].A2 to 1' { | ||||||
|                 $vmr.strip[1].A2 = 1 |                 $vmr.strip[1].A2 = $true | ||||||
|                 $vmr.strip[1].A2 | Should -Be 1 |                 $vmr.strip[1].A2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A2 to 0' { |             It 'Should set Strip[1].A2 to 0' { | ||||||
|                 $vmr.strip[1].A2 = 0 |                 $vmr.strip[1].A2 = $false | ||||||
|                 $vmr.strip[1].A2 | Should -Be 0 |                 $vmr.strip[1].A2 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A2 to 1' { |             It 'Should set Strip[2].A2 to 1' { | ||||||
|                 $vmr.strip[2].A2 = 1 |                 $vmr.strip[2].A2 = $true | ||||||
|                 $vmr.strip[2].A2 | Should -Be 1 |                 $vmr.strip[2].A2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A2 to 0' { |             It 'Should set Strip[2].A2 to 0' { | ||||||
|                 $vmr.strip[2].A2 = 0 |                 $vmr.strip[2].A2 = $false | ||||||
|                 $vmr.strip[2].A2 | Should -Be 0 |                 $vmr.strip[2].A2 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].A3' { |         Context 'Strip[i].A3' { | ||||||
|             It 'Should set Strip[0].A3 to 1' { |             It 'Should set Strip[0].A3 to 1' { | ||||||
|                 $vmr.strip[0].A3 = 1 |                 $vmr.strip[0].A3 = $true | ||||||
|                 $vmr.strip[0].A3 | Should -Be 1 |                 $vmr.strip[0].A3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].A3 to 0' { |             It 'Should set Strip[0].A3 to 0' { | ||||||
|                 $vmr.strip[0].A3 = 0 |                 $vmr.strip[0].A3 = $false | ||||||
|                 $vmr.strip[0].A3 | Should -Be 0 |                 $vmr.strip[0].A3 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A3 to 1' { |             It 'Should set Strip[1].A3 to 1' { | ||||||
|                 $vmr.strip[1].A3 = 1 |                 $vmr.strip[1].A3 = $true | ||||||
|                 $vmr.strip[1].A3 | Should -Be 1 |                 $vmr.strip[1].A3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].A3 to 0' { |             It 'Should set Strip[1].A3 to 0' { | ||||||
|                 $vmr.strip[1].A3 = 0 |                 $vmr.strip[1].A3 = $false | ||||||
|                 $vmr.strip[1].A3 | Should -Be 0 |                 $vmr.strip[1].A3 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A3 to 1' { |             It 'Should set Strip[2].A3 to 1' { | ||||||
|                 $vmr.strip[2].A3 = 1 |                 $vmr.strip[2].A3 = $true | ||||||
|                 $vmr.strip[2].A3 | Should -Be 1 |                 $vmr.strip[2].A3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].A3 to 0' { |             It 'Should set Strip[2].A3 to 0' { | ||||||
|                 $vmr.strip[2].A3 = 0 |                 $vmr.strip[2].A3 = $false | ||||||
|                 $vmr.strip[2].A3 | Should -Be 0 |                 $vmr.strip[2].A3 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].B1' { |         Context 'Strip[i].B1' { | ||||||
|             It 'Should set Strip[0].B1 to 1' { |             It 'Should set Strip[0].B1 to 1' { | ||||||
|                 $vmr.strip[0].B1 = 1 |                 $vmr.strip[0].B1 = $true | ||||||
|                 $vmr.strip[0].B1 | Should -Be 1 |                 $vmr.strip[0].B1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].B1 to 0' { |             It 'Should set Strip[0].B1 to 0' { | ||||||
|                 $vmr.strip[0].B1 = 0 |                 $vmr.strip[0].B1 = $false | ||||||
|                 $vmr.strip[0].B1 | Should -Be 0 |                 $vmr.strip[0].B1 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B1 to 1' { |             It 'Should set Strip[1].B1 to 1' { | ||||||
|                 $vmr.strip[1].B1 = 1 |                 $vmr.strip[1].B1 = $true | ||||||
|                 $vmr.strip[1].B1 | Should -Be 1 |                 $vmr.strip[1].B1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B1 to 0' { |             It 'Should set Strip[1].B1 to 0' { | ||||||
|                 $vmr.strip[1].B1 = 0 |                 $vmr.strip[1].B1 = $false | ||||||
|                 $vmr.strip[1].B1 | Should -Be 0 |                 $vmr.strip[1].B1 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B1 to 1' { |             It 'Should set Strip[2].B1 to 1' { | ||||||
|                 $vmr.strip[2].B1 = 1 |                 $vmr.strip[2].B1 = $true | ||||||
|                 $vmr.strip[2].B1 | Should -Be 1 |                 $vmr.strip[2].B1 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B1 to 0' { |             It 'Should set Strip[2].B1 to 0' { | ||||||
|                 $vmr.strip[2].B1 = 0 |                 $vmr.strip[2].B1 = $false | ||||||
|                 $vmr.strip[2].B1 | Should -Be 0 |                 $vmr.strip[2].B1 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].B2' { |         Context 'Strip[i].B2' { | ||||||
|             It 'Should set Strip[0].B2 to 1' { |             It 'Should set Strip[0].B2 to 1' { | ||||||
|                 $vmr.strip[0].B2 = 1 |                 $vmr.strip[0].B2 = $true | ||||||
|                 $vmr.strip[0].B2 | Should -Be 1 |                 $vmr.strip[0].B2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].B2 to 0' { |             It 'Should set Strip[0].B2 to 0' { | ||||||
|                 $vmr.strip[0].B2 = 0 |                 $vmr.strip[0].B2 = $false | ||||||
|                 $vmr.strip[0].B2 | Should -Be 0 |                 $vmr.strip[0].B2 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B2 to 1' { |             It 'Should set Strip[1].B2 to 1' { | ||||||
|                 $vmr.strip[1].B2 = 1 |                 $vmr.strip[1].B2 = $true | ||||||
|                 $vmr.strip[1].B2 | Should -Be 1 |                 $vmr.strip[1].B2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B2 to 0' { |             It 'Should set Strip[1].B2 to 0' { | ||||||
|                 $vmr.strip[1].B2 = 0 |                 $vmr.strip[1].B2 = $false | ||||||
|                 $vmr.strip[1].B2 | Should -Be 0 |                 $vmr.strip[1].B2 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B2 to 1' { |             It 'Should set Strip[2].B2 to 1' { | ||||||
|                 $vmr.strip[2].B2 = 1 |                 $vmr.strip[2].B2 = $true | ||||||
|                 $vmr.strip[2].B2 | Should -Be 1 |                 $vmr.strip[2].B2 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B2 to 0' { |             It 'Should set Strip[2].B2 to 0' { | ||||||
|                 $vmr.strip[2].B2 = 0 |                 $vmr.strip[2].B2 = $false | ||||||
|                 $vmr.strip[2].B2 | Should -Be 0 |                 $vmr.strip[2].B2 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         Context 'Strip[i].B3' { |         Context 'Strip[i].B3' { | ||||||
|             It 'Should set Strip[0].B3 to 1' { |             It 'Should set Strip[0].B3 to 1' { | ||||||
|                 $vmr.strip[0].B3 = 1 |                 $vmr.strip[0].B3 = $true | ||||||
|                 $vmr.strip[0].B3 | Should -Be 1 |                 $vmr.strip[0].B3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[0].B3 to 0' { |             It 'Should set Strip[0].B3 to 0' { | ||||||
|                 $vmr.strip[0].B3 = 0 |                 $vmr.strip[0].B3 = $false | ||||||
|                 $vmr.strip[0].B3 | Should -Be 0 |                 $vmr.strip[0].B3 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B3 to 1' { |             It 'Should set Strip[1].B3 to 1' { | ||||||
|                 $vmr.strip[1].B3 = 1 |                 $vmr.strip[1].B3 = $true | ||||||
|                 $vmr.strip[1].B3 | Should -Be 1 |                 $vmr.strip[1].B3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[1].B3 to 0' { |             It 'Should set Strip[1].B3 to 0' { | ||||||
|                 $vmr.strip[1].B3 = 0 |                 $vmr.strip[1].B3 = $false | ||||||
|                 $vmr.strip[1].B3 | Should -Be 0 |                 $vmr.strip[1].B3 | Should -Be $false | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B3 to 1' { |             It 'Should set Strip[2].B3 to 1' { | ||||||
|                 $vmr.strip[2].B3 = 1 |                 $vmr.strip[2].B3 = $true | ||||||
|                 $vmr.strip[2].B3 | Should -Be 1 |                 $vmr.strip[2].B3 | Should -Be $true | ||||||
|             } |             } | ||||||
| 
 | 
 | ||||||
|             It 'Should set Strip[2].B3 to 0' { |             It 'Should set Strip[2].B3 to 0' { | ||||||
|                 $vmr.strip[2].B3 = 0 |                 $vmr.strip[2].B3 = $false | ||||||
|                 $vmr.strip[2].B3 | Should -Be 0 |                 $vmr.strip[2].B3 | Should -Be $false | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
|  | |||||||
| @ -6,9 +6,7 @@ try | |||||||
| { | { | ||||||
|     . ..\lib\voicemeeter.ps1 |     . ..\lib\voicemeeter.ps1 | ||||||
| 
 | 
 | ||||||
|     $vmr = [Remote]::new('banana') |     $vmr = [Remote]::new('potato') | ||||||
| 
 |  | ||||||
|     $vmr.Login() |  | ||||||
| 
 | 
 | ||||||
|     1..$num | ForEach-Object { |     1..$num | ForEach-Object { | ||||||
|         Write-Host "Running test $_ of $num" |         Write-Host "Running test $_ of $num" | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user