use strict; use warnings; use Test::More tests => 1; my $have = 'http://www.myurl.com/me.html'; my $want = 'http:\/\/www.myurl.com\/me.html'; $have =~ s#/#\\/#g; is $have, $want;