The parameters are working, but the way you are using them is not. It probably doesn't help that they use the same parameter to allow you to pass in a file or pass in a powershell code snippet.
When using the command you ran above are basically running the PowerShell in between the quotes. Which is open file c:\test.ps1 on the vm you are connecting to without parameters.
az vm run-command invoke --command-id RunPowerShellScript --name my-vm-win -g myRG --scripts "C:\test.ps1" --parameters test=Peter
If you were to run the command like the following you'd see that the parameters are passed into the snippet between the quotes. In this case I'm capturing the parameters sent to the script between the quotes and not to the file directly until I pass it inline to your file on the VM.
az vm run-command invoke --command-id RunPowerShellScript --name my-vm-win -g myRG --scripts "Param([string] $test); C:\Test.ps1 -test $test" --parameters test=Peter
Normally you'd run your snippet using the file that's on the computer you are running it from like the following, and in this case the parameters are passed directly to the file. Note the @ character before the file name indicating that you're using the file on your local client and not the VM.
az vm run-command invoke --command-id RunPowerShellScript --name my-vm-win -g myRG --scripts @C:\Test.ps1 --parameters test=Peter
Basically it would be the equivalent of using this for the script param where the contents of the local file are put in between the quotes like so.
--scripts "Param([string] $test) Write-Output \"Hello $test\""
For one more variation to show you what's going on run this snippet and you'll see that there are 2 arguments sent, one is "-test" and the other is "Peter".
az vm run-command invoke --command-id RunPowerShellScript --name my-vm-win -g myRG --scripts "$args" --parameters test=Peter