in reply to "Casting Question"

$test is a hash reference. So to access the values, you need to use the -> notation:
print $test->{fake_key}, "\n";
See perldoc perlref for more information concerning references.