<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -95,14 +95,11 @@ class PokerHand
   def four_of_a_kind?
     if (md = (by_face =~ /(.). \1. \1. \1./))
       # get kicker
-      (md.pre_match + md.post_match).match(/(\S)/)
-      [
-        [8, Card::face_value(md[1]), Card::face_value($1)],
-        arrange_hand(md)
-      ]
-    else
-      false
+      result = [8, Card::face_value(md[1])]
+      result &lt;&lt; Card::face_value($1) if (md.pre_match + md.post_match).match(/(\S)/)
+      return [result, arrange_hand(md)]
     end
+    false
   end
 
   def full_house?</diff>
      <filename>lib/ruby-poker/poker_hand.rb</filename>
    </modified>
    <modified>
      <diff>@@ -5,12 +5,13 @@ class TestPokerHand &lt; Test::Unit::TestCase
   context &quot;A PokerHand instance&quot; do
   
     setup do
-      @trips = PokerHand.new(&quot;2D 9C AS AH AC&quot;)
-      @pair = PokerHand.new(&quot;As Ac Kc Qd 2s&quot;)
-      @two_pair = PokerHand.new(&quot;As Ac Kc Kd 2s&quot;)
+      @quads = PokerHand.new('Kc Kh Kd Ks Qs')
       @full_boat = PokerHand.new([&quot;2H&quot;, &quot;2D&quot;, &quot;4C&quot;, &quot;4D&quot;, &quot;4S&quot;])
       @flush = PokerHand.new(&quot;3D 6D 7D TD QD 5H 2S&quot;)
       @straight = PokerHand.new(&quot;8H 9D TS JH QC AS&quot;)
+      @trips = PokerHand.new(&quot;2D 9C AS AH AC&quot;)
+      @two_pair = PokerHand.new(&quot;As Ac Kc Kd 2s&quot;)
+      @pair = PokerHand.new(&quot;As Ac Kc Qd 2s&quot;)
       @ace_high = PokerHand.new(&quot;As Jh 9c 7d 5s&quot;)
     end
   
@@ -19,18 +20,21 @@ class TestPokerHand &lt; Test::Unit::TestCase
     end
 
     should &quot;handle two card hands&quot; do
-      p = PokerHand.new('As Ac')
-      assert_equal(p.rank, @pair.rank)
+      assert_equal(PokerHand.new('As Ac').rank, @pair.rank)
     end
 
     should &quot;handle three card hands&quot; do
-      p = PokerHand.new('As Ac Ah')
-      assert_equal(p.rank, @trips.rank)
+      assert_equal(PokerHand.new('As Ac Ah').rank, @trips.rank)
     end
 
     should &quot;handle four card hands&quot; do
-      p = PokerHand.new('As Ac Kd Kh')
-      assert_equal(p.rank, @two_pair.rank)
+      assert_equal(PokerHand.new('As Ac Kd Kh').rank, @two_pair.rank)
+      assert_equal(PokerHand.new('As Ac Ad Ah').rank, @quads.rank)
+    end
+
+    should &quot;handle lower case face card names&quot; do
+      assert_equal(0, PokerHand.new('kc kd') &lt;=&gt; PokerHand.new('Kc Kd'))
+      assert_equal(0, PokerHand.new('kc kd') &lt;=&gt; PokerHand.new('Kc KD'))
     end
 
     # there are a lot of combinations that should be tested here. I will add more
@@ -237,7 +241,6 @@ class TestPokerHand &lt; Test::Unit::TestCase
         PokerHand.allow_duplicates = true
       end
     end
-    
   end
 end
 </diff>
      <filename>test/test_poker_hand.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>66c507761a51d60b5cff6920b42564cdf12f3037</id>
    </parent>
  </parents>
  <author>
    <name>Jonathan Wilkins</name>
    <email>jwilkins@jwilkins-mbp.local</email>
  </author>
  <url>http://github.com/robolson/ruby-poker/commit/38c94c98eeafbe3f7f9ce7327482742d925016fc</url>
  <id>38c94c98eeafbe3f7f9ce7327482742d925016fc</id>
  <committed-date>2009-10-27T11:05:51-07:00</committed-date>
  <authored-date>2009-10-27T11:05:51-07:00</authored-date>
  <message>handle 4 card hands for quads</message>
  <tree>eb4e7d3a8fd48bea8cb6e0f3e7ed2c2f06f62a66</tree>
  <committer>
    <name>Jonathan Wilkins</name>
    <email>jwilkins@jwilkins-mbp.local</email>
  </committer>
</commit>
