<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -2,10 +2,11 @@
 require &quot;#{File.dirname(__FILE__)}/test_helper&quot;
 
 class SimpleTest &lt; Test::Unit::TestCase
-
-  ThriftClient::Simple.make_struct(&quot;Example&quot;, ThriftClient::Simple::Field.new(:name, ThriftClient::Simple::STRING, 1))
-  ThriftClient::Simple.make_struct(&quot;Args&quot;)
-  ThriftClient::Simple.make_struct(&quot;Retval&quot;, ThriftClient::Simple::Field.new(:rv, ThriftClient::Simple::I32, 0))
+ 
+  S = ThriftClient::Simple
+  S.make_struct(&quot;Example&quot;, S::Field.new(:name, S::STRING, 1))
+  S.make_struct(&quot;Args&quot;)
+  S.make_struct(&quot;Retval&quot;, S::Field.new(:rv, S::I32, 0))
  
   def test_definition
     assert Struct::ST_Example
@@ -16,102 +17,121 @@ class SimpleTest &lt; Test::Unit::TestCase
   ## Encoding
 
   def test_boolean_encoding
-    assert_equal &quot;\001&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::BOOL, true)
-    assert_equal &quot;\000&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::BOOL, false)
+    assert_equal &quot;\001&quot;, S.pack_value(S::BOOL, true)
+    assert_equal &quot;\000&quot;, S.pack_value(S::BOOL, false)
   end
 
   def test_byte_encoding
-    assert_equal &quot;\xc7&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::BYTE, 199)
+    assert_equal &quot;\xc7&quot;, S.pack_value(S::BYTE, 199)
   end
 
   def test_i16_encoding
-    assert_equal &quot;\x00\x96&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::I16, 150)
+    assert_equal &quot;\x00\x96&quot;, S.pack_value(S::I16, 150)
   end
 
   def test_i32_encoding
-    assert_equal &quot;\x00\x96\xb4\x3f&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::I32, 9876543)
+    assert_equal &quot;\x00\x96\xb4\x3f&quot;, S.pack_value(S::I32, 9876543)
   end
 
   def test_i64_encoding
-    assert_equal &quot;\x00\x00\x00\x1c\xbb\xf3\x09\x04&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::I64, 123412351236)
+    assert_equal &quot;\x00\x00\x00\x1c\xbb\xf3\x09\x04&quot;, S.pack_value(S::I64, 123412351236)
   end
 
   def test_double_encoding
-    assert_equal &quot;\x40\x23\x00\x00\x00\x00\x00\x00&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::DOUBLE, 9.5)
+    assert_equal &quot;\x40\x23\x00\x00\x00\x00\x00\x00&quot;, S.pack_value(S::DOUBLE, 9.5)
   end
 
   def test_string_encoding
-    assert_equal &quot;\x00\x00\x00\x05hello&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::STRING, &quot;hello&quot;)
+    assert_equal &quot;\x00\x00\x00\x05hello&quot;, S.pack_value(S::STRING, &quot;hello&quot;)
   end
 
   def test_list_encoding
-    assert_equal &quot;\x08\x00\x00\x00\x03\x00\x00\x00\x17\x00\x00\x00\x16\x00\x00\x00\x15&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::ListType.new(ThriftClient::Simple::I32), [ 23, 22, 21 ])
+    assert_equal &quot;\x08\x00\x00\x00\x03\x00\x00\x00\x17\x00\x00\x00\x16\x00\x00\x00\x15&quot;, 
+      S.pack_value(S::ListType.new(S::I32), [ 23, 22, 21 ])
   end
 
   def test_map_encoding
-    assert_equal &quot;\x0b\x08\x00\x00\x00\x01\x00\x00\x00\x03cat\x00\x00\x00\x05&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::MapType.new(ThriftClient::Simple::STRING, ThriftClient::Simple::I32), &quot;cat&quot; =&gt; 5)
+    assert_equal &quot;\x0b\x08\x00\x00\x00\x01\x00\x00\x00\x03cat\x00\x00\x00\x05&quot;, 
+      S.pack_value(S::MapType.new(S::STRING, S::I32), &quot;cat&quot; =&gt; 5)
   end
 
   def test_set_encoding
-    assert_equal &quot;\x08\x00\x00\x00\x01\x00\x00\x00\x04&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::SetType.new(ThriftClient::Simple::I32), [ 4 ])
+    assert_equal &quot;\x08\x00\x00\x00\x01\x00\x00\x00\x04&quot;, 
+      S.pack_value(S::SetType.new(S::I32), [ 4 ])
   end
 
   def test_struct_encoding
-    assert_equal &quot;\x0b\x00\x01\x00\x00\x00\x06Commie\x00&quot;, ThriftClient::Simple.pack_value(ThriftClient::Simple::StructType.new(Struct::ST_Example), Struct::ST_Example.new(&quot;Commie&quot;))
+    assert_equal &quot;\x0b\x00\x01\x00\x00\x00\x06Commie\x00&quot;, 
+      S.pack_value(S::StructType.new(Struct::ST_Example), Struct::ST_Example.new(&quot;Commie&quot;))
   end
 
   def test_request_encoding
-    assert_equal &quot;\x80\x01\x00\x01\x00\x00\x00\x09getHeight\x00\x00\x00\x17\x00&quot;, ThriftClient::Simple.pack_request(&quot;getHeight&quot;, Struct::ST_Args.new, 23)
+    assert_equal &quot;\x80\x01\x00\x01\x00\x00\x00\x09getHeight\x00\x00\x00\x17\x00&quot;, 
+      S.pack_request(&quot;getHeight&quot;, Struct::ST_Args.new, 23)
   end
   
   ## Decoding
 
   def test_boolean_decoding
-    assert_equal  true, ThriftClient::Simple.read_value(StringIO.new(&quot;\x01&quot;), ThriftClient::Simple::BOOL)
-    assert_equal  false, ThriftClient::Simple.read_value(StringIO.new(&quot;\x00&quot;), ThriftClient::Simple::BOOL)
+    assert_equal true, S.read_value(StringIO.new(&quot;\x01&quot;), S::BOOL)
+    assert_equal false, S.read_value(StringIO.new(&quot;\x00&quot;), S::BOOL)
   end
 
   def test_byte_decoding
-    assert_equal  -57, ThriftClient::Simple.read_value(StringIO.new(&quot;\xc7&quot;), ThriftClient::Simple::BYTE)
+    assert_equal -57, S.read_value(StringIO.new(&quot;\xc7&quot;), S::BYTE)
   end
 
   def test_i16_decoding
-    assert_equal  150, ThriftClient::Simple.read_value(StringIO.new(&quot;\x00\x96&quot;), ThriftClient::Simple::I16)
+    assert_equal 150, S.read_value(StringIO.new(&quot;\x00\x96&quot;), S::I16)
   end
 
   def test_i32_decoding
-    assert_equal  9876543, ThriftClient::Simple.read_value(StringIO.new(&quot;\x00\x96\xb4\x3f&quot;), ThriftClient::Simple::I32)
+    assert_equal 9876543, S.read_value(StringIO.new(&quot;\x00\x96\xb4\x3f&quot;), S::I32)
   end
 
   def test_i64_decoding
-    assert_equal  123412351236, ThriftClient::Simple.read_value(StringIO.new(&quot;\x00\x00\x00\x1c\xbb\xf3\x09\x04&quot;), ThriftClient::Simple::I64)
+    assert_equal 123412351236, 
+      S.read_value(StringIO.new(&quot;\x00\x00\x00\x1c\xbb\xf3\x09\x04&quot;), S::I64)
   end
 
   def test_double_decoding
-    assert_equal  9.5, ThriftClient::Simple.read_value(StringIO.new(&quot;\x40\x23\x00\x00\x00\x00\x00\x00&quot;), ThriftClient::Simple::DOUBLE)
+    assert_equal 9.5, 
+      S.read_value(StringIO.new(&quot;\x40\x23\x00\x00\x00\x00\x00\x00&quot;), S::DOUBLE)
   end
 
   def test_string_decoding
-    assert_equal &quot;hello&quot;, ThriftClient::Simple.read_value(StringIO.new(&quot;\x00\x00\x00\x05hello&quot;), ThriftClient::Simple::STRING)
+    assert_equal &quot;hello&quot;, S.read_value(StringIO.new(&quot;\x00\x00\x00\x05hello&quot;), S::STRING)
   end
 
   def test_list_decoding
-    assert_equal  [ 23, 22, 21 ], ThriftClient::Simple.read_value(StringIO.new(&quot;\x08\x00\x00\x00\x03\x00\x00\x00\x17\x00\x00\x00\x16\x00\x00\x00\x15&quot;), ThriftClient::Simple::ListType.new(ThriftClient::Simple::I32))
-    end
+    assert_equal [ 23, 22, 21 ], 
+      S.read_value(StringIO.new(&quot;\x08\x00\x00\x00\x03\x00\x00\x00\x17\x00\x00\x00\x16\x00\x00\x00\x15&quot;), 
+      S::ListType.new(S::I32))
+  end
 
   def test_map_decoding
-    assert_equal({ &quot;cat&quot; =&gt; 5 }, ThriftClient::Simple.read_value(StringIO.new(&quot;\x0b\x08\x00\x00\x00\x01\x00\x00\x00\x03cat\x00\x00\x00\x05&quot;), ThriftClient::Simple::MapType.new(ThriftClient::Simple::STRING, ThriftClient::Simple::I32)))
+    assert_equal({ &quot;cat&quot; =&gt; 5 }, 
+      S.read_value(StringIO.new(&quot;\x0b\x08\x00\x00\x00\x01\x00\x00\x00\x03cat\x00\x00\x00\x05&quot;), 
+      S::MapType.new(S::STRING, S::I32)))
   end
 
   def test_set_decoding
-    assert_equal  [ 4 ], ThriftClient::Simple.read_value(StringIO.new(&quot;\x08\x00\x00\x00\x01\x00\x00\x00\x04&quot;), ThriftClient::Simple::ListType.new(ThriftClient::Simple::I32))
+    assert_equal [ 4 ], 
+      S.read_value(StringIO.new(&quot;\x08\x00\x00\x00\x01\x00\x00\x00\x04&quot;), 
+      S::ListType.new(S::I32))
   end
 
   def test_struct_decoding
-    assert_equal  Struct::ST_Example.new(&quot;Commie&quot;), ThriftClient::Simple.read_value(StringIO.new(&quot;\x0b\x00\x01\x00\x00\x00\x06Commie\x00&quot;), ThriftClient::Simple::StructType.new(Struct::ST_Example))
+    assert_equal Struct::ST_Example.new(&quot;Commie&quot;), 
+      S.read_value(StringIO.new(&quot;\x0b\x00\x01\x00\x00\x00\x06Commie\x00&quot;), 
+      S::StructType.new(Struct::ST_Example))
   end
 
   def test_response_decoding
-    assert_equal  [ &quot;getHeight&quot;, 255, 1 ], ThriftClient::Simple.read_response(StringIO.new(&quot;\x80\x01\x00\x02\x00\x00\x00\x09getHeight\x00\x00\x00\xff\x08\x00\x00\x00\x00\x00\x01\x00&quot;), Struct::ST_Retval)
+    assert_equal [ &quot;getHeight&quot;, 255, 1 ], 
+      S.read_response(
+      StringIO.new(&quot;\x80\x01\x00\x02\x00\x00\x00\x09getHeight\x00\x00\x00\xff\x08\x00\x00\x00\x00\x00\x01\x00&quot;),
+      Struct::ST_Retval)
   end
+  
 end</diff>
      <filename>test/simple_test.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>4c9aef6da985c637decbb95a073936033e693cd9</id>
    </parent>
  </parents>
  <author>
    <name>Evan Weaver</name>
    <email>eweaver@twitter.com</email>
  </author>
  <url>http://github.com/fauna/thrift_client/commit/fe1b2cd50c7db49811837f7661836985a6077e5b</url>
  <id>fe1b2cd50c7db49811837f7661836985a6077e5b</id>
  <committed-date>2009-10-26T11:57:28-07:00</committed-date>
  <authored-date>2009-10-26T11:43:41-07:00</authored-date>
  <message>Formatting.</message>
  <tree>a2ca3d8d32952747b415dbf6e5c454ec6701ff95</tree>
  <committer>
    <name>Evan Weaver</name>
    <email>eweaver@twitter.com</email>
  </committer>
</commit>
