First of all I'm new to PowerShell so please forgive if it is dumb. I wanted to add testing to my script. So I thought about Pester. But I came across an issue.
Unfortunately my prod environment has PowerShell v2 and also I have to have whole script in one file. On my local I have v5 so I can use its benefits while testing. The problem is that my script is a mix of functions and commands and it seems that if I have this: