diff options
author | Kjetil Ørbekk <kjetil.orbekk@gmail.com> | 2012-04-24 12:41:25 +0200 |
---|---|---|
committer | Kjetil Ørbekk <kjetil.orbekk@gmail.com> | 2012-04-24 12:41:25 +0200 |
commit | ae8791a096626b0196c63e4d9cb68f7a18ad86b0 (patch) | |
tree | b661f744548beaf647e3f734864b2bd15acfcbb7 /same/src/test/java | |
parent | 2ef7691606aa86b10e16be93efa9cc7c277c8050 (diff) |
Switch to protobuf based Paxos in functional test.
Diffstat (limited to 'same/src/test/java')
-rw-r--r-- | same/src/test/java/com/orbekk/same/FunctionalTest.java | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/same/src/test/java/com/orbekk/same/FunctionalTest.java b/same/src/test/java/com/orbekk/same/FunctionalTest.java index 79bd9b8..c0b710e 100644 --- a/same/src/test/java/com/orbekk/same/FunctionalTest.java +++ b/same/src/test/java/com/orbekk/same/FunctionalTest.java @@ -53,8 +53,9 @@ public class FunctionalTest { connections.clientMap0.put(location, client.getNewService()); clients.add(client); String paxosUrl = clientUrl.replace("ClientService", "PaxosService"); - PaxosService paxos = new PaxosServiceImpl(paxosUrl); + PaxosServiceImpl paxos = new PaxosServiceImpl(paxosUrl); connections.paxosMap.put(paxosUrl, paxos); + connections.paxosMap0.put(location, paxos.getService()); return client; } @@ -86,10 +87,10 @@ public class FunctionalTest { @Test public void testJoin() { joinClients(); for (State s : getStates()) { - List<String> participants = s.getList(".participants"); - assertThat(participants, hasItem("http://client1/ClientService.json")); - assertThat(participants, hasItem("http://client2/ClientService.json")); - assertThat(participants, hasItem("http://client3/ClientService.json")); + List<String> participants = s.getList(State.PARTICIPANTS); + assertThat(participants, hasItem("client1")); + assertThat(participants, hasItem("client2")); + assertThat(participants, hasItem("client3")); } for (Client c : clients) { assertThat(c.getConnectionState(), is(ConnectionState.STABLE)); |