Functions/Get-Puppeteer_DeclareUsernameAndPassword.Tests.ps1
describe "BitTitan.Runbooks.UIAutomation/Get-Puppeteer_DeclareUsernameAndPassword" -Tag "module", "unit" { # Import the function to test . "$($PSScriptRoot)\Get-Puppeteer_DeclareUsernameAndPassword.ps1" it "returns the code for declaring username and password variables" { # Call the function $output = Get-Puppeteer_DeclareUsernameAndPassword -Credential ([PSCredential]::new("username", ("password" | ConvertTo-SecureString -AsPlainText -Force))) # Verify the output $output | Should Be @" const username = "username"; const password = "password"; "@ } } |