Functions/Get-Puppeteer_EnterVariableIntoSelector.Tests.ps1
describe "BitTitan.Runbooks.UIAutomation/Get-Puppeteer_EnterVariableIntoSelector" -Tags "module", "unit" { # Import the function to test . "$($PSScriptRoot)\Get-Puppeteer_EnterVariableIntoSelector.ps1" it "returns the code for entering the value of a variable into a selector" { # Call the function $output = Get-Puppeteer_EnterVariableIntoSelector -SelectorName "#selector" -VariableName "answer" # Verify the output $output | Should Be @" selector = '#selector'; await page.waitForSelector(selector); await page.type(selector, answer); "@ } } |