Index: simplerunner/src/test/java/geniusweb/simplerunner/ClassPathConnectionFactoryTest.java
===================================================================
--- simplerunner/src/test/java/geniusweb/simplerunner/ClassPathConnectionFactoryTest.java	(revision 52)
+++ simplerunner/src/test/java/geniusweb/simplerunner/ClassPathConnectionFactoryTest.java	(revision 1)
@@ -1,5 +1,4 @@
 package geniusweb.simplerunner;
 
-import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 
@@ -11,17 +10,15 @@
 
 import geniusweb.actions.Action;
-import geniusweb.connection.ConnectionEnd;
-import geniusweb.inform.Inform;
+import geniusweb.connection.Connection;
+import geniusweb.party.inform.Inform;
 import geniusweb.references.PartyRef;
+import geniusweb.simplerunner.ClassPathConnectionFactory;
 
 public class ClassPathConnectionFactoryTest {
 	private ClassPathConnectionFactory factory;
-	private PartyRef PARTYREF;
 
 	@Before
-	public void before() throws URISyntaxException {
+	public void before() {
 		factory = new ClassPathConnectionFactory();
-		PARTYREF = new PartyRef(
-				"classpath:geniusweb.exampleparties.randomparty.RandomParty");
 
 	}
@@ -45,51 +42,8 @@
 	@Test
 	public void testRandomParty() throws IOException, URISyntaxException {
-		ConnectionEnd<Action, Inform> party = factory.connect(PARTYREF);
+		Connection<Action, Inform> party = factory.connect(new PartyRef(
+				"classpath:geniusweb.exampleparties.randomparty.RandomParty"));
 		assertNotNull(party);
 	}
 
-	@Test
-	public void testConnectionPairProtocolClosesNormally()
-			throws InterruptedException {
-		ConnectionPair cpair = new ConnectionPair(PARTYREF);
-		assertEquals(2, cpair.getOpenConnections().size());
-		cpair.getProtocolToPartyConn().close();
-		Thread.sleep(100);
-
-		assertEquals(0, cpair.getOpenConnections().size());
-
-	}
-
-	@Test
-	public void testConnectionPairProtocolClosesWithExc()
-			throws InterruptedException {
-		ConnectionPair cpair = new ConnectionPair(PARTYREF);
-		assertEquals(2, cpair.getOpenConnections().size());
-		cpair.getProtocolToPartyConn().setError(new Error("test"));
-		Thread.sleep(100);
-		assertEquals(0, cpair.getOpenConnections().size());
-	}
-
-	@Test
-	public void testConnectionPairPartyClosesNormally()
-			throws InterruptedException {
-		ConnectionPair cpair = new ConnectionPair(PARTYREF);
-		assertEquals(2, cpair.getOpenConnections().size());
-		cpair.getPartyToProtocolConn().close();
-		Thread.sleep(100);
-
-		assertEquals(0, cpair.getOpenConnections().size());
-
-	}
-
-	@Test
-	public void testConnectionPairPartyClosesWithExc()
-			throws InterruptedException {
-		ConnectionPair cpair = new ConnectionPair(PARTYREF);
-		assertEquals(2, cpair.getOpenConnections().size());
-		cpair.getPartyToProtocolConn().setError(new Error("test"));
-		Thread.sleep(100);
-		assertEquals(0, cpair.getOpenConnections().size());
-	}
-
 }
Index: simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerE2ETest.java
===================================================================
--- simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerE2ETest.java	(revision 52)
+++ simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerE2ETest.java	(revision 1)
@@ -1,10 +1,3 @@
 package geniusweb.simplerunner;
-
-import static org.junit.Assert.assertTrue;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.eq;
-import static org.mockito.Mockito.spy;
-import static org.mockito.Mockito.times;
-import static org.mockito.Mockito.verify;
 
 import java.io.IOException;
@@ -12,17 +5,13 @@
 import java.nio.file.Files;
 import java.nio.file.Paths;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.logging.Level;
 
 import org.junit.Before;
 import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
-import org.junit.runners.Parameterized.Parameters;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
 
-import geniusweb.protocol.NegoSettings;
+import geniusweb.protocol.session.SessionSettings;
+import geniusweb.simplerunner.ClassPathConnectionFactory;
+import geniusweb.simplerunner.NegoRunner;
 import tudelft.utilities.logging.ReportToLogger;
 import tudelft.utilities.logging.Reporter;
@@ -33,38 +22,20 @@
  * this module.
  */
-@RunWith(Parameterized.class)
 public class SessionRunnerE2ETest {
-	private static final int TEST_RUNTIME = 5000;
+	private static final String SESSION_SETTINGS = "src/test/resources/settings.json";
 	private final ObjectMapper jackson = new ObjectMapper();
-	private Runner runner;
-	private Reporter logger = spy(new ReportToLogger("test"));
-	private String filename;
-
-	@Parameters
-	public static Collection<Object[]> data() {
-		return Arrays
-				.asList(new Object[][] { { "src/test/resources/settings.json" },
-						{ "src/test/resources/settings2.json" },
-						{ "src/test/resources/settingsbadprofile.json" },
-						{ "src/test/resources/shaoptoursettings.json" },
-						{ "src/test/resources/mopac.json" },
-						{ "src/test/resources/tournament.json" },
-						{ "src/test/resources/tournamentlearn.json" } });
-	}
-
-	public SessionRunnerE2ETest(String file) {
-		this.filename = file;
-	}
+	private NegoRunner runner;
+	private Reporter logger = new ReportToLogger("test");
 
 	@Before
 	public void before() throws IOException {
-		System.out.println("Running from file " + filename);
-		String serialized = new String(Files.readAllBytes(Paths.get(filename)),
+		String serialized = new String(
+				Files.readAllBytes(Paths.get(SESSION_SETTINGS)),
 				StandardCharsets.UTF_8);
-		NegoSettings settings = jackson.readValue(serialized,
-				NegoSettings.class);
+		SessionSettings settings = jackson.readValue(serialized,
+				SessionSettings.class);
 
-		runner = new Runner(settings, new ClassPathConnectionFactory(), logger,
-				TEST_RUNTIME);
+		runner = new NegoRunner(settings, new ClassPathConnectionFactory(),
+				logger);
 
 	}
@@ -77,13 +48,9 @@
 	public void runTest() throws IOException {
 		runner.run();
-		System.out.println("Final state:\n" + runner.getProtocol().getState());
-		assertTrue(runner.isProperlyStopped());
-		verify(logger, times(0)).log(eq(Level.WARNING), any());
-		verify(logger, times(0)).log(eq(Level.SEVERE), any());
 	}
 
 	@Test
 	public void runTestMainFunction() throws IOException {
-		NegoRunner.main(new String[] { filename });
+		NegoRunner.main(new String[] { SESSION_SETTINGS });
 	}
 }
Index: simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerTest.java
===================================================================
--- simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerTest.java	(revision 52)
+++ simplerunner/src/test/java/geniusweb/simplerunner/SessionRunnerTest.java	(revision 1)
@@ -1,7 +1,7 @@
 package geniusweb.simplerunner;
 
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.anyLong;
-import static org.mockito.ArgumentMatchers.eq;
+import static org.mockito.Matchers.any;
+import static org.mockito.Matchers.anyLong;
+import static org.mockito.Matchers.eq;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.spy;
@@ -16,11 +16,11 @@
 import org.mockito.ArgumentCaptor;
 
-import geniusweb.actions.PartyId;
 import geniusweb.protocol.CurrentNegoState;
-import geniusweb.protocol.NegoState;
 import geniusweb.protocol.ProtocolException;
+import geniusweb.protocol.partyconnection.ConnectionWithPartyFactory;
 import geniusweb.protocol.session.SessionProtocol;
 import geniusweb.protocol.session.SessionSettings;
 import geniusweb.protocol.session.SessionState;
+import geniusweb.simplerunner.NegoRunner;
 import tudelft.utilities.listener.Listener;
 import tudelft.utilities.logging.ReportToLogger;
@@ -29,5 +29,5 @@
 public class SessionRunnerTest {
 	private static final ProtocolException PROTOCOL_EXC = new ProtocolException(
-			"fake protocol exception", new PartyId("test"));
+			"fake protocol exception", "test");
 	private CurrentNegoState finishedEvent;
 	private final long NOW = 1000;
@@ -46,6 +46,6 @@
 	@Test
 	public void smokeTest() {
-		new Runner(mock(SessionSettings.class),
-				mock(ClassPathConnectionFactory.class), logger, 5000);
+		new NegoRunner(mock(SessionSettings.class),
+				mock(ConnectionWithPartyFactory.class), logger);
 	}
 
@@ -56,8 +56,9 @@
 		when(settings.getProtocol(logger)).thenReturn(protocol);
 		@SuppressWarnings("unchecked")
-		ClassPathConnectionFactory factory = mock(
-				ClassPathConnectionFactory.class);
+		ConnectionWithPartyFactory factory = mock(
+				ConnectionWithPartyFactory.class);
 
-		Runner runner = spy(new Runner(settings, factory, logger, 5000));
+		NegoRunner runner = spy(
+				new NegoRunner(settings, factory, logger));
 		runner.run();
 
@@ -75,15 +76,12 @@
 		when(settings.getProtocol(any())).thenReturn(protocol);
 		SessionState state = mock(SessionState.class);
+		when(state.getError()).thenReturn(null);
 		when(protocol.getState()).thenReturn(state);
 		Reporter logger = mock(Reporter.class);
 		@SuppressWarnings("unchecked")
-		ClassPathConnectionFactory factory = mock(
-				ClassPathConnectionFactory.class);
-		Runner runner = spy(new Runner(settings, factory, logger, 5000) {
-			@Override
-			protected void logFinal(Level level, NegoState state) {
-				log.log(level, state.toString());
-			}
-		});
+		ConnectionWithPartyFactory factory = mock(
+				ConnectionWithPartyFactory.class);
+		NegoRunner runner = spy(
+				new NegoRunner(settings, factory, logger));
 		ArgumentCaptor<Listener> listener = ArgumentCaptor
 				.forClass(Listener.class);
@@ -95,5 +93,5 @@
 		listener.getValue().notifyChange(finishedEvent);
 		verify(runner, times(1)).stop();
-		verify(logger, times(0)).log(eq(Level.WARNING), any(String.class));
+		verify(logger, times(1)).log(eq(Level.INFO), any(String.class));
 
 	}
@@ -106,14 +104,11 @@
 		when(settings.getProtocol(any())).thenReturn(protocol);
 		SessionState state = mock(SessionState.class);
+		when(state.getError()).thenReturn(PROTOCOL_EXC);
 		when(protocol.getState()).thenReturn(state);
 		@SuppressWarnings("unchecked")
-		ClassPathConnectionFactory factory = mock(
-				ClassPathConnectionFactory.class);
-		Runner runner = spy(new Runner(settings, factory, logger, 5000) {
-			@Override
-			protected void logFinal(Level level, NegoState state) {
-				log.log(level, state.toString());
-			}
-		});
+		ConnectionWithPartyFactory factory = mock(
+				ConnectionWithPartyFactory.class);
+		NegoRunner runner = spy(
+				new NegoRunner(settings, factory, logger));
 		ArgumentCaptor<Listener> listener = ArgumentCaptor
 				.forClass(Listener.class);
@@ -124,8 +119,7 @@
 		listener.getValue().notifyChange(finishedEvent);
 		verify(runner, times(1)).stop();
-		// check final state is logged
-		String statestr = state.toString();
-		verify(logger, times(1)).log(any(), eq(statestr));
-
+		// check that the protocol error is logged properly
+		verify(logger, times(1)).log(eq(Level.WARNING), any(String.class),
+				eq(PROTOCOL_EXC));
 	}
 
