Run your tests using the correct Perl. The normal invocation is prove -lr t/, but if you're using Dist::Zilla you can just do dzil test. Your post implies that your tests are running your included shell script though, which indicates they are executing it wrong. Your tests must use $^X as the perl executable so they run using the Perl being installed to.
Comment on Re: Proper handling of shebang line while performing local testing?
Thanks. I can't remember now but I think I was using dzil test and it still wasn't working (but this was before I had the `perl` command in there to try to get it to work on Windows). I will try with the $^X special variable. I didn't know that existed until now.
$PM = "Perl Monk's";
$MCF = "Most Clueless FriarAbbotBishopPontiffDeaconCurate Priest";
$nysus = $PM . ' ' . $MCF; Click here if you love Perl Monks