Thrift: Whitespace cleanup.

Summary:
- Expanded tabs to spaces where spaces were the norm.
- Deleted almost all trailing whitespace.
- Added newlines to the ends of a few files.
- Ran dos2unix on one file or two.

Reviewed By: mcslee

Test Plan: git diff -b

Revert Plan: ok


git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665467 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/DocTest.thrift b/test/DocTest.thrift
index c94d426..5749fda 100755
--- a/test/DocTest.thrift
+++ b/test/DocTest.thrift
@@ -29,7 +29,7 @@
 }
 
 /** This is how you would do a typedef doc */
-typedef i64 UserId 
+typedef i64 UserId
 
 /** And this is where you would document a struct */
 struct Xtruct
@@ -68,7 +68,7 @@
   1: map<Numberz, UserId> userMap,
 
   /** And this is doc for field 2 */
-  2: list<Xtruct> xtructs 
+  2: list<Xtruct> xtructs
 }
 
 exception Xception {
@@ -80,7 +80,7 @@
   1: i32 errorCode,
   2: Xtruct struct_thing
 }
- 
+
 /* C1 */
 /** Doc */
 /* C2 */
diff --git a/test/FastbinaryTest.py b/test/FastbinaryTest.py
index f6a8699..b27612b 100755
--- a/test/FastbinaryTest.py
+++ b/test/FastbinaryTest.py
@@ -104,7 +104,7 @@
   o.write(prot)
 
   slow_version_binary = prot.trans.getvalue()
-  
+
   prot = TBinaryProtocol.TBinaryProtocolAccelerated(
            TTransport.TMemoryBuffer(slow_version_binary))
   c = o.__class__()
diff --git a/test/SmallTest.thrift b/test/SmallTest.thrift
index 58357fe..bded87a 100644
--- a/test/SmallTest.thrift
+++ b/test/SmallTest.thrift
@@ -24,7 +24,7 @@
 exception Goodbye {
   1: i32 simple,
   2: map<i32,i32> complex,
-  3: map<i32, map<i32,i32>> complexer,  
+  3: map<i32, map<i32,i32>> complexer,
 }
 
 service SmallService {
diff --git a/test/cpp/Makefile.thrift b/test/cpp/Makefile.thrift
index 9eb1dce..fa412aa 100644
--- a/test/cpp/Makefile.thrift
+++ b/test/cpp/Makefile.thrift
@@ -1,5 +1,5 @@
 # Makefile for Thrift test project.
-# 
+#
 # Author:
 #   Mark Slee <mcslee@facebook.com>
 
@@ -44,7 +44,7 @@
 	$(THRIFT) --cpp ../ThriftTest.thrift
 
 server-debug: stubs
-	g++ -o TestServer $(DCFL) src/TestServer.cpp ./gen-cpp/ThriftTest.cpp ./gen-cpp/ThriftTest_types.cpp 
+	g++ -o TestServer $(DCFL) src/TestServer.cpp ./gen-cpp/ThriftTest.cpp ./gen-cpp/ThriftTest_types.cpp
 
 client-debug: stubs
 	g++ -o TestClient $(DCFL) src/TestClient.cpp ./gen-cpp/ThriftTest.cpp ./gen-cpp/ThriftTest_types.cpp
diff --git a/test/cpp/src/TestClient.cpp b/test/cpp/src/TestClient.cpp
index c2efb1a..9b350b0 100644
--- a/test/cpp/src/TestClient.cpp
+++ b/test/cpp/src/TestClient.cpp
@@ -25,7 +25,7 @@
 {
   long long ret;
   struct timeval tv;
-  
+
   gettimeofday(&tv, NULL);
   ret = tv.tv_sec;
   ret = ret*1000*1000 + tv.tv_usec;
@@ -63,7 +63,7 @@
   shared_ptr<TTransport> transport;
 
   shared_ptr<TSocket> socket(new TSocket(host, port));
-  
+
   if (framed) {
     shared_ptr<TFramedTransport> framedSocket(new TFramedTransport(socket));
     framedSocket->setRead(frameInput);
@@ -84,7 +84,7 @@
   uint64_t time_min = 0;
   uint64_t time_max = 0;
   uint64_t time_tot = 0;
- 
+
   int test = 0;
   for (test = 0; test < numTests; ++test) {
 
@@ -94,14 +94,14 @@
       printf("Connect failed: %s\n", ttx.what());
       continue;
     }
-    
+
     /**
      * CONNECT TEST
      */
     printf("Test #%d, connect %s:%d\n", test+1, host.c_str(), port);
 
     uint64_t start = now();
-    
+
     /**
      * VOID TEST
      */
@@ -112,7 +112,7 @@
     } catch (TApplicationException tax) {
       printf("%s\n", tax.what());
     }
-    
+
     /**
      * STRING TEST
      */
@@ -120,14 +120,14 @@
     string s;
     testClient.testString(s, "Test");
     printf(" = \"%s\"\n", s.c_str());
-   
+
     /**
      * BYTE TEST
      */
     printf("testByte(1)");
     uint8_t u8 = testClient.testByte(1);
     printf(" = %d\n", (int)u8);
- 
+
     /**
      * I32 TEST
      */
@@ -148,7 +148,7 @@
     printf("testDouble(-5.2098523)");
     double dub = testClient.testDouble(-5.2098523);
     printf(" = %lf\n", dub);
-    
+
     /**
      * STRUCT TEST
      */
@@ -165,7 +165,7 @@
            (int)in.byte_thing,
            in.i32_thing,
            in.i64_thing);
-    
+
     /**
      * NESTED STRUCT TEST
      */
@@ -183,7 +183,7 @@
            (int)in.byte_thing,
            in.i32_thing,
            in.i64_thing,
-           in2.i32_thing);   
+           in2.i32_thing);
 
     /**
      * MAP TEST
@@ -387,11 +387,11 @@
       printf("testClient.testException(\"Xception\") =>");
       testClient.testException("Xception");
       printf("  void\nFAILURE\n");
-      
+
     } catch(Xception& e) {
       printf("  {%u, \"%s\"}\n", e.errorCode, e.message.c_str());
     }
-    
+
     try {
       printf("testClient.testException(\"success\") =>");
       testClient.testException("success");
@@ -399,9 +399,9 @@
     } catch(...) {
       printf("  exception\nFAILURE\n");
     }
-    
+
     /* test multi exception */
-    
+
     try {
       printf("testClient.testMultiException(\"Xception\", \"test 1\") =>");
       Xtruct result;
@@ -416,11 +416,11 @@
       Xtruct result;
       testClient.testMultiException(result, "Xception2", "test 2");
       printf("  result\nFAILURE\n");
-      
+
     } catch(Xception2& e) {
       printf("  {%u, {\"%s\"}}\n", e.errorCode, e.struct_thing.string_thing.c_str());
     }
-    
+
     try {
       printf("testClient.testMultiException(\"success\", \"test 3\") =>");
       Xtruct result;
@@ -429,12 +429,12 @@
     } catch(...) {
       printf("  exception\nFAILURE\n");
     }
-    
+
     uint64_t stop = now();
     uint64_t tot = stop-start;
 
     printf("Total time: %"PRIu64" us\n", stop-start);
-    
+
     time_tot += tot;
     if (time_min == 0 || tot < time_min) {
       time_min = tot;
diff --git a/test/cpp/src/TestServer.cpp b/test/cpp/src/TestServer.cpp
index 3afc955..773225e 100644
--- a/test/cpp/src/TestServer.cpp
+++ b/test/cpp/src/TestServer.cpp
@@ -146,7 +146,7 @@
 
   void testInsanity(map<UserId, map<Numberz,Insanity> > &insane, const Insanity &argument) {
     printf("testInsanity()\n");
-    
+
     Xtruct hello;
     hello.string_thing = "Hello2";
     hello.byte_thing = 2;
@@ -210,12 +210,12 @@
     }
     printf("}\n");
 
-    
+
   }
 
   void testMulti(Xtruct &hello, const int8_t arg0, const int32_t arg1, const int64_t arg2, const std::map<int16_t, std::string>  &arg3, const Numberz arg4, const UserId arg5) {
     printf("testMulti()\n");
-    
+
     hello.string_thing = "Hello2";
     hello.byte_thing = arg0;
     hello.i32_thing = arg1;
@@ -235,7 +235,7 @@
       return;
     }
   }
-  
+
   void testMultiException(Xtruct &result, const std::string &arg0, const std::string &arg1) throw(Xception, Xception2) {
 
     printf("testMultiException(%s, %s)\n", arg0.c_str(), arg1.c_str());
@@ -275,9 +275,9 @@
     "\t\tprotocol-type\t\ttype of protocol, \"binary\", \"ascii\", or \"xml\".  Default is " << protocolType << endl <<
 
     "\t\tworkers\t\tNumber of thread pools workers.  Only valid for thread-pool server type.  Default is " << workerCount << endl;
-    
+
   map<string, string>  args;
-  
+
   for (int ix = 1; ix < argc; ix++) {
     string arg(argv[ix]);
     if (arg.compare(0,2, "--") == 0) {
@@ -303,7 +303,7 @@
     }
 
     if (!args["server-type"].empty()) {
-      serverType = args["server-type"];     
+      serverType = args["server-type"];
       if (serverType == "simple") {
       } else if (serverType == "thread-pool") {
       } else if (serverType == "threaded") {
@@ -323,7 +323,7 @@
       } else {
 	throw invalid_argument("Unknown protocol type "+protocolType);
       }
-    } 
+    }
 
     if (!args["workers"].empty()) {
       workerCount = atoi(args["workers"].c_str());
@@ -379,7 +379,7 @@
     threadPoolServer.serve();
 
   } else if (serverType == "threaded") {
-    
+
     TThreadedServer threadedServer(testProcessor,
                                    serverSocket,
                                    transportFactory,
diff --git a/test/cpp/src/main.cpp b/test/cpp/src/main.cpp
index 160ca8f..78491d6 100644
--- a/test/cpp/src/main.cpp
+++ b/test/cpp/src/main.cpp
@@ -49,8 +49,8 @@
 };
 
 
-// typedef hash_map<const char*, int, hash<const char*>, eqstr> count_map; 
-typedef map<const char*, int, ltstr> count_map; 
+// typedef hash_map<const char*, int, hash<const char*>, eqstr> count_map;
+typedef map<const char*, int, ltstr> count_map;
 
 class Server : public ServiceIf {
  public:
@@ -105,12 +105,12 @@
 
   void run() {
 
-    // Wait for all worker threads to start 
+    // Wait for all worker threads to start
 
     {Synchronized s(_monitor);
-	while(_workerCount == 0) {
-	  _monitor.wait();
-	}
+      while(_workerCount == 0) {
+        _monitor.wait();
+      }
     }
 
     _startTime = Util::currentTime();
@@ -125,20 +125,20 @@
     case T_STRING: loopEchoString(); break;
     default: cerr << "Unexpected loop type" << _loopType << endl; break;
     }
-    
+
     _endTime = Util::currentTime();
 
     _transport->close();
-    
+
     _done = true;
-      
+
     {Synchronized s(_monitor);
 
       _workerCount--;
-	  
+
       if (_workerCount == 0) {
-	
-	_monitor.notify();
+
+        _monitor.notify();
       }
     }
   }
@@ -157,7 +157,7 @@
       assert(result == arg);
     }
   }
-  
+
   void loopEchoI32() {
     for (size_t ix = 0; ix < _loopCount; ix++) {
       int32_t arg = 1;
@@ -175,7 +175,7 @@
       assert(result == arg);
     }
   }
-    
+
   void loopEchoString() {
     for (size_t ix = 0; ix < _loopCount; ix++) {
       string arg = "hello";
@@ -184,7 +184,7 @@
       assert(result == arg);
     }
   }
-  
+
   shared_ptr<TTransport> _transport;
   shared_ptr<ServiceClient> _client;
   Monitor& _monitor;
@@ -228,10 +228,10 @@
     "\tlog-request    Log all request to ./requestlog.tlog. Default is " << logRequests << endl <<
     "\treplay-request Replay requests from log file (./requestlog.tlog) Default is " << replayRequests << endl <<
     "\tworkers        Number of thread pools workers.  Only valid for thread-pool server type.  Default is " << workerCount << endl;
-    
-        
+
+
   map<string, string>  args;
-  
+
   for (int ix = 1; ix < argc; ix++) {
 
     string arg(argv[ix]);
@@ -243,9 +243,9 @@
       string key = string(arg, 2, end - 2);
 
       if (end != string::npos) {
-	args[key] = string(arg, end + 1);
+        args[key] = string(arg, end + 1);
       } else {
-	args[key] = "true";
+        args[key] = "true";
       }
     } else {
       throw invalid_argument("Unexcepted command line token: "+arg);
@@ -289,7 +289,7 @@
 
     if (!args["server-type"].empty()) {
       serverType = args["server-type"];
-      
+
       if (serverType == "simple") {
 
       } else if (serverType == "thread-pool") {
@@ -298,7 +298,7 @@
 
       } else {
 
-	throw invalid_argument("Unknown server type "+serverType);
+        throw invalid_argument("Unknown server type "+serverType);
       }
     }
 
@@ -319,7 +319,7 @@
   if (replayRequests) {
     shared_ptr<Server> serviceHandler(new Server());
     shared_ptr<ServiceProcessor> serviceProcessor(new ServiceProcessor(serviceHandler));
-  
+
     // Transports
     shared_ptr<TFileTransport> fileTransport(new TFileTransport(requestLogPath));
     fileTransport->setChunkSize(2 * 1024 * 1024);
@@ -333,7 +333,7 @@
                                  protocolFactory,
                                  fileTransport);
 
-    fileProcessor.process(0, true);                                     
+    fileProcessor.process(0, true);
     exit(0);
   }
 
@@ -356,34 +356,34 @@
       shared_ptr<TFileTransport> fileTransport(new TFileTransport(requestLogPath));
       fileTransport->setChunkSize(2 * 1024 * 1024);
       fileTransport->setMaxEventSize(1024 * 16);
-      
-      transportFactory = 
+
+      transportFactory =
         shared_ptr<TTransportFactory>(new TPipedTransportFactory(fileTransport));
     }
 
     shared_ptr<Thread> serverThread;
 
     if (serverType == "simple") {
-      
+
       serverThread = threadFactory->newThread(shared_ptr<TServer>(new TSimpleServer(serviceProcessor, serverSocket, transportFactory, protocolFactory)));
-      
+
     } else if (serverType == "threaded") {
 
       serverThread = threadFactory->newThread(shared_ptr<TServer>(new TThreadedServer(serviceProcessor, serverSocket, transportFactory, protocolFactory)));
-      
+
     } else if (serverType == "thread-pool") {
 
       shared_ptr<ThreadManager> threadManager = ThreadManager::newSimpleThreadManager(workerCount);
 
       threadManager->threadFactory(threadFactory);
-      threadManager->start();     
+      threadManager->start();
       serverThread = threadFactory->newThread(shared_ptr<TServer>(new TThreadPoolServer(serviceProcessor, serverSocket, transportFactory, protocolFactory, threadManager)));
     }
 
     cerr << "Starting the server on port " << port << endl;
 
     serverThread->start();
-    
+
     // If we aren't running clients, just wait forever for external clients
 
     if (clientCount == 0) {
@@ -407,77 +407,77 @@
     else {throw invalid_argument("Unknown service call "+callName);}
 
     for (size_t ix = 0; ix < clientCount; ix++) {
-    
+
       shared_ptr<TSocket> socket(new TSocket("127.0.01", port));
       shared_ptr<TBufferedTransport> bufferedSocket(new TBufferedTransport(socket, 2048));
       shared_ptr<TProtocol> protocol(new TBinaryProtocol(bufferedSocket));
       shared_ptr<ServiceClient> serviceClient(new ServiceClient(protocol));
-    
+
       clientThreads.insert(threadFactory->newThread(shared_ptr<ClientThread>(new ClientThread(socket, serviceClient, monitor, threadCount, loopCount, loopType))));
     }
-  
+
     for (std::set<shared_ptr<Thread> >::const_iterator thread = clientThreads.begin(); thread != clientThreads.end(); thread++) {
       (*thread)->start();
     }
 
     long long time00;
     long long time01;
-  
+
     {Synchronized s(monitor);
       threadCount = clientCount;
-    
+
       cerr << "Launch "<< clientCount << " client threads" << endl;
-    
+
       time00 =  Util::currentTime();
-    
+
       monitor.notifyAll();
-      
+
       while(threadCount > 0) {
-	monitor.wait();
+        monitor.wait();
       }
-    
+
       time01 =  Util::currentTime();
     }
-  
+
     long long firstTime = 9223372036854775807LL;
     long long lastTime = 0;
 
     double averageTime = 0;
     long long minTime = 9223372036854775807LL;
     long long maxTime = 0;
-  
+
     for (set<shared_ptr<Thread> >::iterator ix = clientThreads.begin(); ix != clientThreads.end(); ix++) {
-      
+
       shared_ptr<ClientThread> client = dynamic_pointer_cast<ClientThread>((*ix)->runnable());
-      
+
       long long delta = client->_endTime - client->_startTime;
-      
+
       assert(delta > 0);
 
       if (client->_startTime < firstTime) {
-	firstTime = client->_startTime;
+        firstTime = client->_startTime;
       }
-      
+
       if (client->_endTime > lastTime) {
-	lastTime = client->_endTime;
+        lastTime = client->_endTime;
       }
-      
+
       if (delta < minTime) {
-	minTime = delta;
+        minTime = delta;
       }
-      
+
       if (delta > maxTime) {
-	maxTime = delta;
+        maxTime = delta;
       }
-      
+
       averageTime+= delta;
     }
-    
+
     averageTime /= clientCount;
-    
-    
+
+
     cout <<  "workers :" << workerCount << ", client : " << clientCount << ", loops : " << loopCount << ", rate : " << (clientCount * loopCount * 1000) / ((double)(time01 - time00)) << endl;
-    
+
     count_map count = serviceHandler->getCount();
     count_map::iterator iter;
     for (iter = count.begin(); iter != count.end(); ++iter) {
diff --git a/test/hs/Client.hs b/test/hs/Client.hs
index 10e5929..fa9c8e7 100644
--- a/test/hs/Client.hs
+++ b/test/hs/Client.hs
@@ -26,4 +26,4 @@
           print =<< testSet ps (Set.fromList [1,2,3,4,5])
           print =<< testStruct ps (Xtruct (Just "hi") (Just 4) (Just 5) Nothing)
           tclose to
-          
+
diff --git a/test/java/src/TestServer.java b/test/java/src/TestServer.java
index 0d01be9..5a844a3 100644
--- a/test/java/src/TestServer.java
+++ b/test/java/src/TestServer.java
@@ -24,7 +24,7 @@
   public static class TestHandler implements ThriftTest.Iface {
 
     public TestHandler() {}
-  
+
     public void testVoid() {
       System.out.print("testVoid()\n");
     }
@@ -53,7 +53,7 @@
       System.out.print("testDouble(" + thing + ")\n");
       return thing;
     }
-  
+
     public Xtruct testStruct(Xtruct thing) {
       System.out.print("testStruct({" +
                        "\"" + thing.string_thing + "\", " +
@@ -62,7 +62,7 @@
                        thing.i64_thing + "})\n");
       return thing;
     }
-  
+
     public Xtruct2 testNest(Xtruct2 nest) {
       Xtruct thing = nest.struct_thing;
       System.out.print("testNest({" +
@@ -74,7 +74,7 @@
                        nest.i32_thing + "})\n");
       return nest;
     }
-  
+
     public AbstractMap<Integer,Integer> testMap(AbstractMap<Integer,Integer> thing) {
       System.out.print("testMap({");
       boolean first = true;
@@ -150,7 +150,7 @@
 
     public AbstractMap<Long, AbstractMap<Integer,Insanity>> testInsanity(Insanity argument) {
       System.out.print("testInsanity()\n");
-    
+
       Xtruct hello = new Xtruct();
       hello.string_thing = "Hello2";
       hello.byte_thing = 2;
@@ -192,7 +192,7 @@
 
     public Xtruct testMulti(byte arg0, int arg1, long arg2, AbstractMap<Short,String> arg3, int arg4, long arg5) {
       System.out.print("testMulti()\n");
-    
+
       Xtruct hello = new Xtruct();;
       hello.string_thing = "Hello2";
       hello.byte_thing = arg0;
@@ -226,7 +226,7 @@
         x.struct_thing.string_thing = "This is an Xception2";
         throw x;
       }
-     
+
       Xtruct result = new Xtruct();
       result.string_thing = arg1;
       return result;
@@ -240,7 +240,7 @@
       if (args.length > 1) {
         port = Integer.valueOf(args[0]);
       }
-      
+
       // Processor
       TestHandler testHandler =
         new TestHandler();
diff --git a/test/ocaml/server/TestServer.ml b/test/ocaml/server/TestServer.ml
index afcd789..3768f5d 100644
--- a/test/ocaml/server/TestServer.ml
+++ b/test/ocaml/server/TestServer.ml
@@ -24,7 +24,7 @@
   method testList x = p "testList(---)\n"; (sod x)
   method testEnum x = p "testEnum(---)\n"; (sod x)
   method testTypedef x = p "testTypedef(---)\n"; (sod x)
-  method testMapMap x = p "testMapMap(%d)\n" (sod x); 
+  method testMapMap x = p "testMapMap(%d)\n" (sod x);
     let mm = Hashtbl.create 3 in
     let pos = Hashtbl.create 7 in
     let neg = Hashtbl.create 7 in
@@ -63,7 +63,7 @@
       Hashtbl.add insane 1L firstmap;
       Hashtbl.add insane 2L secondmap;
       insane
-  method testMulti a0 a1 a2 a3 a4 a5 = 
+  method testMulti a0 a1 a2 a3 a4 a5 =
     p "testMulti()\n";
     let hello = new xtruct in
       hello#set_string_thing "Hello2";
@@ -103,13 +103,13 @@
 let proc = new ThriftTest.processor h in
 let port = 9090 in
 let pf = new TBinaryProtocol.factory in
-let server = new TThreadedServer.t 
-  proc 
-  (new TServerSocket.t port) 
-  (new Transport.factory) 
-  pf 
-  pf 
+let server = new TThreadedServer.t
+  proc
+  (new TServerSocket.t port)
+  (new Transport.factory)
+  pf
+  pf
 in
   server#serve
-                                             
-                                 
+
+
diff --git a/test/perl/Makefile b/test/perl/Makefile
index 0e99a73..128bbe8 100644
--- a/test/perl/Makefile
+++ b/test/perl/Makefile
@@ -1,5 +1,5 @@
 # Makefile for Thrift test project.
-# 
+#
 # Author:
 #   Mark Slee <mcslee@facebook.com>
 
diff --git a/test/py/Makefile b/test/py/Makefile
index b4b2718..2049663 100644
--- a/test/py/Makefile
+++ b/test/py/Makefile
@@ -1,5 +1,5 @@
 # Makefile for Thrift test project.
-# 
+#
 # Author:
 #   Mark Slee <mcslee@facebook.com>
 
diff --git a/test/py/RunClientServer.py b/test/py/RunClientServer.py
index 0f5c46f..21f4531 100644
--- a/test/py/RunClientServer.py
+++ b/test/py/RunClientServer.py
@@ -7,7 +7,7 @@
 
 serverproc = subprocess.Popen([sys.executable, "TestServer.py"])
 try:
-    
+
     ret = subprocess.call([sys.executable, "TestClient.py"])
     if ret != 0:
         raise Exception("subprocess failed")
diff --git a/test/py/TestClient.py b/test/py/TestClient.py
index 63ec1d0..7e58dfe 100755
--- a/test/py/TestClient.py
+++ b/test/py/TestClient.py
@@ -15,7 +15,7 @@
 
 
 parser = OptionParser()
-    
+
 parser.add_option("--port", type="int", dest="port", default=9090)
 parser.add_option("--host", type="string", dest="host", default='localhost')
 parser.add_option("--framed-input", action="store_true", dest="framed_input")
@@ -24,12 +24,12 @@
 (options, args) = parser.parse_args()
 
 class AbstractTest(unittest.TestCase):
-  
+
   def setUp(self):
     global options
-    
+
     socket = TSocket.TSocket(options.host, options.port)
-    
+
     # Frame or buffer depending upon args
     if options.framed_input or options.framed_output:
       self.transport = TTransport.TFramedTransport(socket, options.framed_input, options.framed_output)
@@ -37,17 +37,17 @@
       self.transport = TTransport.TBufferedTransport(socket)
 
     self.transport.open()
-    
+
     protocol = self.protocol_factory.getProtocol(self.transport)
     self.client = ThriftTest.Client(protocol)
-    
+
   def tearDown(self):
     # Close!
     self.transport.close()
 
   def testVoid(self):
     self.client.testVoid()
-    
+
   def testString(self):
     self.assertEqual(self.client.testString('Python'), 'Python')
 
diff --git a/test/py/TestServer.py b/test/py/TestServer.py
index 6cd9f58..94a81c0 100755
--- a/test/py/TestServer.py
+++ b/test/py/TestServer.py
@@ -1,6 +1,6 @@
 #!/usr/bin/env python
 
-import sys, glob 
+import sys, glob
 sys.path.insert(0, './gen-py')
 sys.path.insert(0, glob.glob('../../lib/py/build/lib.*')[0])
 
diff --git a/test/py/TestSocket.py b/test/py/TestSocket.py
index 7cbdf5c..b693d18 100755
--- a/test/py/TestSocket.py
+++ b/test/py/TestSocket.py
@@ -31,7 +31,7 @@
 
     def testConnectTimeout(self):
         starttime = time.time()
-        
+
         try:
             leaky = []
             for i in xrange(100):
@@ -44,7 +44,7 @@
 
     def testWriteTimeout(self):
         starttime = time.time()
-        
+
         try:
             socket = TSocket.TSocket('localhost', self.port)
             socket.setTimeout(10)
@@ -52,10 +52,10 @@
             lsock = self.listen_sock.accept()
             while True:
                 socket.write("hi" * 100)
-            
+
         except:
             assert time.time() - starttime < 5.0
-            
+
 suite = unittest.TestSuite()
 loader = unittest.TestLoader()
 
diff --git a/test/rb/Makefile b/test/rb/Makefile
index 5ea5305..502a981 100644
--- a/test/rb/Makefile
+++ b/test/rb/Makefile
@@ -1,5 +1,5 @@
 # Makefile for Thrift test project.
-# 
+#
 # Author:
 #   Mark Slee <mcslee@facebook.com>
 
diff --git a/test/rb/TestSmallService.rb b/test/rb/TestSmallService.rb
index 9ac287a..277b54c 100644
--- a/test/rb/TestSmallService.rb
+++ b/test/rb/TestSmallService.rb
@@ -14,7 +14,7 @@
 
     assert_kind_of(Hello, hello)
     assert_nil(hello.complexer)
-    
+
     assert_equal(hello.simple, 53)
     assert_equal(hello.words, 'words')
 
diff --git a/test/rb/TestThrift.rb b/test/rb/TestThrift.rb
index 2b59fa9..e35e808 100644
--- a/test/rb/TestThrift.rb
+++ b/test/rb/TestThrift.rb
@@ -126,7 +126,7 @@
   def test_insane
     insane = Thrift::Test::Insanity.new({
       'userMap' => { Thrift::Test::Numberz::ONE => 44 },
-      'xtructs' => [get_struct, 
+      'xtructs' => [get_struct,
         Thrift::Test::Xtruct.new({
           'string_thing' => 'hi again',
           'i32_thing' => 12
diff --git a/test/threads/Makefile b/test/threads/Makefile
index 58aebef..58cdf18 100644
--- a/test/threads/Makefile
+++ b/test/threads/Makefile
@@ -1,5 +1,5 @@
 # Makefile for Thrift test project.
-# 
+#
 # Author:
 #   Mark Slee <mcslee@facebook.com>
 
diff --git a/test/threads/ThreadsServer.cpp b/test/threads/ThreadsServer.cpp
index a293cfb..826bbdb 100644
--- a/test/threads/ThreadsServer.cpp
+++ b/test/threads/ThreadsServer.cpp
@@ -90,13 +90,13 @@
   shared_ptr<TProtocolFactory> protocolFactory(new TBinaryProtocolFactory());
 
   /*
-  shared_ptr<ThreadManager> threadManager = 
+  shared_ptr<ThreadManager> threadManager =
     ThreadManager::newSimpleThreadManager(10);
   shared_ptr<PosixThreadFactory> threadFactory =
     shared_ptr<PosixThreadFactory>(new PosixThreadFactory());
   threadManager->threadFactory(threadFactory);
   threadManager->start();
- 
+
   shared_ptr<TServer> server =
     shared_ptr<TServer>(new TThreadPoolServer(processor,
                                               serverTransport,