The test fails because the proxy has not (always) received the membership events and still points to `first`. msg 22 ends up in deadletters at `first`. The following patch should solve it:

    From 3f3d84bf9e1d8cc7ff1827088ac923517864e7f4 Mon Sep 17 00:00:00 2001
    From: Patrik Nordwall <patrik.nordwall@gmail.com>
    Date: Thu, 6 Mar 2014 12:39:43 +0100
    Subject: [PATCH] testfix

    ---
     .../contrib/pattern/ClusterSingletonManagerSpec.scala  | 18 +++++++++++++++++-
     1 file changed, 17 insertions(+), 1 deletion(-)

    diff --git a/akka-contrib/src/multi-jvm/scala/akka/contrib/pattern/ClusterSingletonManagerSpec.scala b/akka-contrib/src/multi-jvm/scala/akka/contrib/pattern/ClusterSingletonManagerSpec.scala
    index 02cc8f1..3b1f911 100644
    --- a/akka-contrib/src/multi-jvm/scala/akka/contrib/pattern/ClusterSingletonManagerSpec.scala
    +++ b/akka-contrib/src/multi-jvm/scala/akka/contrib/pattern/ClusterSingletonManagerSpec.scala
    @@ -117,8 +117,9 @@ object ClusterSingletonManagerSpec extends MultiNodeConfig {
       object Consumer {
     
         case object End
    -
         case object GetCurrent
    +    case object Ping
    +    case object Pong
     
       }
     
    @@ -150,6 +151,8 @@ object ClusterSingletonManagerSpec extends MultiNodeConfig {
           case UnregistrationOk ⇒
             context stop self
           //#consumer-end
    +      case Ping ⇒
    +        sender ! Pong
         }
       }
     
    @@ -279,6 +282,19 @@ class ClusterSingletonManagerSpec extends MultiNodeSpec(ClusterSingletonManagerS
     
         // send a message to the proxy
         runOn(proxyNode) {
    +      // make sure that the proxy has received membership changes
    +      // and points to the current singleton
    +      val p = TestProbe()
    +      within(5.seconds) {
    +        awaitAssert {
    +          println("#Ping")
    +          system.actorSelection("/user/consumerProxy").tell(Ping, p.ref)
    +          p.expectMsg(1.second, Pong)
    +          println("#Pong")
    +        }
    +      }
    +
    +      // then send the real message
           system.actorSelection("/user/consumerProxy") ! msg
         }
     
    -- 
    1.8.3.4 (Apple Git-47)