THRIFT-193: Patch for proper namespace support in perl compiler

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@728863 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/perl/TestClient.pl b/test/perl/TestClient.pl
index 82e8320..ef5ff91 100644
--- a/test/perl/TestClient.pl
+++ b/test/perl/TestClient.pl
@@ -1,4 +1,4 @@
-#!/usr/bin/perl
+#!/usr/bin/env perl
 
 require 5.6.0;
 use strict;
@@ -7,14 +7,14 @@
 use Time::HiRes qw(gettimeofday);
 
 use lib '../../lib/perl/lib';
-use lib '../gen-perl';
+use lib 'gen-perl';
 
 use Thrift;
 use Thrift::BinaryProtocol;
 use Thrift::Socket;
 use Thrift::BufferedTransport;
 
-use ThriftTest;
+use ThriftTest::ThriftTest;
 use ThriftTest::Types;
 
 $|++;
@@ -28,7 +28,7 @@
 my $bufferedSocket = new Thrift::BufferedTransport($socket, 1024, 1024);
 my $transport = $bufferedSocket;
 my $protocol = new Thrift::BinaryProtocol($transport);
-my $testClient = new ThriftTestClient($protocol);
+my $testClient = new ThriftTest::ThriftTestClient($protocol);
 
 eval{
 $transport->open();
@@ -177,23 +177,23 @@
 # ENUM TEST
 #
 print("testEnum(ONE)");
-my $ret = $testClient->testEnum(Numberz::ONE);
+my $ret = $testClient->testEnum(ThriftTest::Numberz::ONE);
 print(" = $ret\n");
 
 print("testEnum(TWO)");
-$ret = $testClient->testEnum(Numberz::TWO);
+$ret = $testClient->testEnum(ThriftTest::Numberz::TWO);
 print(" = $ret\n");
 
 print("testEnum(THREE)");
-$ret = $testClient->testEnum(Numberz::THREE);
+$ret = $testClient->testEnum(ThriftTest::Numberz::THREE);
 print(" = $ret\n");
 
 print("testEnum(FIVE)");
-$ret = $testClient->testEnum(Numberz::FIVE);
+$ret = $testClient->testEnum(ThriftTest::Numberz::FIVE);
 print(" = $ret\n");
 
 print("testEnum(EIGHT)");
-$ret = $testClient->testEnum(Numberz::EIGHT);
+$ret = $testClient->testEnum(ThriftTest::Numberz::EIGHT);
 print(" = $ret\n");
 
 #
@@ -222,7 +222,7 @@
 # INSANITY TEST
 #
 my $insane = new ThriftTest::Insanity();
-$insane->{userMap}->{Numberz::FIVE} = 5000;
+$insane->{userMap}->{ThriftTest::Numberz::FIVE} = 5000;
 my $truck = new ThriftTest::Xtruct();
 $truck->string_thing("Truck");
 $truck->byte_thing(8);