Index: bidspace/src/test/java/geniusweb/bidspace/BidsWithUtilityTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/BidsWithUtilityTest.java	(revision 52)
+++ 	(revision )
@@ -1,154 +1,0 @@
-package geniusweb.bidspace;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.math.RoundingMode;
-import java.nio.file.Files;
-import java.nio.file.Paths;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Random;
-
-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.issuevalue.Bid;
-import geniusweb.profile.Profile;
-import geniusweb.profile.utilityspace.LinearAdditiveUtilitySpace;
-import tudelft.utilities.immutablelist.ImmutableList;
-
-@RunWith(Parameterized.class)
-public class BidsWithUtilityTest {
-	private final static ObjectMapper jackson = new ObjectMapper();
-	private final Interval utilityGoal = new Interval(new BigDecimal("0.50"),
-			new BigDecimal("0.51"));
-	private LinearAdditiveUtilitySpace profile;
-	private long expectedSize;
-	private int accuracy = 5;
-	private final static Runtime r = Runtime.getRuntime();
-
-	@Parameters
-	public static Collection<Object[]> data() {
-		return Arrays.asList(new Object[][] {
-				{ "src/test/resources/jobs/jobs1.json", 11 },
-				{ "src/test/resources/7issues/7issues1.json", 260000 },
-				{ "src/test/resources/9issues/9issues1.json", 25000000 } });
-	}
-
-	public BidsWithUtilityTest(String filename, long expectedsize)
-			throws IOException {
-		String file = new String(Files.readAllBytes(Paths.get(filename)));
-		profile = (LinearAdditiveUtilitySpace) jackson.readValue(file,
-				Profile.class);
-		this.expectedSize = expectedsize;
-	}
-
-	/**
-	 * Test if the values are within acceptable range from the goal.
-	 */
-	@Test
-	public void test() {
-		ImmutableList<Bid> list = new BidsWithUtility(profile, accuracy)
-				.getBids(utilityGoal);
-		Random rand = new Random();
-		// check not all but only 10000 random bids as list may be way too large
-		// to test them all. Testing 1 billion bids may take 15 minutes or so on
-		// quad core i7 @2.4GHz.....
-		// also notice that we may be checking only part of the list if
-		// the size of the list would become bigger than maxint.
-		for (int n = 0; n < 10000; n++) {
-			Bid bid = list.get(rand.nextInt(list.size().intValue()));
-			assertTrue(utilityGoal.contains(profile.getUtility(bid)
-					.setScale(accuracy - 1, RoundingMode.HALF_UP)));
-		}
-		assertTrue(
-				list.size().compareTo(BigInteger.valueOf(expectedSize)) >= 0);
-
-	}
-
-	@Test
-	public void testMaxUtil() {
-		BidsWithUtility bidswithutil = new BidsWithUtility(profile);
-		// notice, this is the *rounded* max util
-		BigDecimal maxutil = bidswithutil.getRange().getMax();
-		Interval goal = new Interval(
-				maxutil.subtract(new BigDecimal("0.00001")), maxutil);
-
-		ImmutableList<Bid> bidsnearmax = bidswithutil.getBids(goal);
-		assertTrue(bidsnearmax.size() != BigInteger.ZERO);
-
-		BigDecimal foundmax = BigDecimal.ZERO;
-		for (Bid bid : bidsnearmax) {
-			BigDecimal util = profile.getUtility(bid);
-			if (util.compareTo(foundmax) > 0) {
-				foundmax = util;
-			}
-		}
-		// found maximum may be slightly lower or higher because we rounded
-		// all weighted utilities.
-		assertTrue(Math
-				.abs(foundmax.doubleValue() - maxutil.doubleValue()) < 0.0001);
-	}
-
-	@Test
-	public void benchmark() {
-		System.out.println("\nBenchmarking " + profile.getName());
-		BigInteger domainsize = new AllBidsList(profile.getDomain()).size();
-
-		long presize = usedMemory();
-		long start = System.currentTimeMillis();
-		BidsWithUtility body = new BidsWithUtility(profile, accuracy);
-		ImmutableList<Bid> list = body.getBids(utilityGoal);
-		long end = System.currentTimeMillis();
-		long postsize = usedMemory();
-		System.out.println("run time: " + (end - start) / 1000. + "s");
-		System.out.println("Total size of complete domain:" + domainsize);
-		System.out.println("size of selection: " + list.size());
-		System.out.println("Memory use of selection(MB):"
-				+ (double) (postsize - presize) / (1024 * 1024));
-	}
-
-	/**
-	 * see https://www.geeksforgeeks.org/java-lang-runtime-class-in-java/
-	 * 
-	 * @return currently used memory after doing GC.
-	 * 
-	 */
-	public static long usedMemory() {
-		for (int n = 0; n < 4; n++)
-			gc1(); // repeat as gct seems getting more agressive then
-		return used();
-	}
-
-	/**
-	 * 
-	 * @return used heap mem. Does NOT GC. Uses {@link Runtime#totalMemory()}
-	 *         and {@link Runtime#freeMemory()} to avoid problems when JVM gets
-	 *         more system memory which can happen at any time.
-	 */
-	private static long used() {
-		return r.totalMemory() - r.freeMemory();
-	}
-
-	/**
-	 * repeat garbage collection till heap memory gets stable
-	 */
-	private static void gc1() {
-		long usedMem1 = used(), usedMem2 = Long.MAX_VALUE;
-		for (int i = 0; (usedMem1 < usedMem2) && (i < 500); ++i) {
-			r.runFinalization();
-			r.gc();
-			Thread.currentThread().yield();
-
-			usedMem2 = usedMem1;
-			usedMem1 = used();
-		}
-	}
-}
Index: bidspace/src/test/java/geniusweb/bidspace/FrequencyOppModelTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/FrequencyOppModelTest.java	(revision 1)
+++ bidspace/src/test/java/geniusweb/bidspace/FrequencyOppModelTest.java	(revision 1)
@@ -0,0 +1,138 @@
+package geniusweb.bidspace;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import java.math.BigDecimal;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+
+import org.junit.Test;
+
+import geniusweb.bidspace.FrequencyOpponentModel;
+import geniusweb.bidspace.OpponentModel;
+import geniusweb.issuevalue.Bid;
+import geniusweb.issuevalue.DiscreteValue;
+import geniusweb.issuevalue.DiscreteValueSet;
+import geniusweb.issuevalue.Domain;
+import geniusweb.issuevalue.NumberValue;
+import geniusweb.issuevalue.NumberValueSet;
+import geniusweb.issuevalue.Value;
+import geniusweb.issuevalue.ValueSet;
+import tudelft.utilities.junit.GeneralTests;
+
+public class FrequencyOppModelTest extends GeneralTests<FrequencyOpponentModel> {
+	private final static String ISS1 = "issue1";
+	private final static String ISS2 = "issue2";
+	private static final DiscreteValue I1V1 = new DiscreteValue("i1v1");
+	private static final DiscreteValue I1V2 = new DiscreteValue("i1v2");
+	private static final DiscreteValue I1V2b = new DiscreteValue("i1v2b");
+
+	private static Domain domain, domain2, domain3;
+	private static FrequencyOpponentModel oppModel1, oppModel1b, oppModel2, oppModel3, oppModel4;
+
+	private final static List<List<Bid>> list = new LinkedList<>();
+
+	private final static Bid bid1, bid2, bid3;
+	private static final BigDecimal HALF = new BigDecimal("0.5");
+
+	static {
+		Map<String, ValueSet> issues = new HashMap<>();
+		Collection<DiscreteValue> discretevalues1 = new LinkedList<>();
+		discretevalues1.add(I1V1);
+		discretevalues1.add(I1V2);
+		DiscreteValueSet values1 = new DiscreteValueSet(discretevalues1);
+		issues.put(ISS1, values1);
+		NumberValueSet values2 = new NumberValueSet(BigDecimal.ZERO, BigDecimal.TEN, new BigDecimal("0.3"));
+		issues.put(ISS2, values2);
+		domain = new Domain("test", issues);
+		domain2 = new Domain("test2", issues);
+
+		// slightly different issue1
+		issues = new HashMap<>();
+		discretevalues1 = new LinkedList<>();
+		discretevalues1.add(I1V1);
+		discretevalues1.add(I1V2b);
+		values1 = new DiscreteValueSet(discretevalues1);
+		issues.put(ISS1, values1);
+		values2 = new NumberValueSet(BigDecimal.ZERO, BigDecimal.TEN, new BigDecimal("0.3"));
+		issues.put(ISS2, values2);
+		domain3 = new Domain("test", issues);
+
+		// all bids are for domain
+		Map<String, Value> issuevalues = new HashMap<>();
+		issuevalues.put(ISS1, I1V1);
+		issuevalues.put(ISS2, new NumberValue(new BigDecimal("1.2")));
+		bid1 = new Bid(issuevalues);
+
+		issuevalues.put(ISS1, I1V1);
+		issuevalues.put(ISS2, new NumberValue(new BigDecimal("1.5")));
+		bid2 = new Bid(issuevalues);
+
+		issuevalues.put(ISS1, I1V2);
+		issuevalues.put(ISS2, new NumberValue(new BigDecimal("1.5")));
+		bid3 = new Bid(issuevalues);
+
+		oppModel1 = new FrequencyOpponentModel(domain);
+		oppModel1b = new FrequencyOpponentModel(domain);
+		oppModel2 = new FrequencyOpponentModel(domain2);
+		oppModel3 = new FrequencyOpponentModel(domain3);
+		oppModel4 = (FrequencyOpponentModel) oppModel3.update(bid1);
+
+	}
+
+	@Override
+	public List<List<FrequencyOpponentModel>> getGeneralTestData() {
+		return Arrays.asList(Arrays.asList(oppModel1, oppModel1b), Arrays.asList(oppModel2), Arrays.asList(oppModel3),
+				Arrays.asList(oppModel4));
+	}
+
+	@Override
+	public List<String> getGeneralTestStrings() {
+		return Arrays.asList("FrequencyOpponentModel\\[0,\\{issue2=\\{\\}, issue1=\\{\\}\\}\\]",
+				"FrequencyOpponentModel\\[0,\\{issue2=\\{\\}, issue1=\\{\\}\\}\\]",
+				"FrequencyOpponentModel\\[0,\\{issue2=\\{\\}, issue1=\\{\\}\\}\\]",
+				"FrequencyOpponentModel\\[1,\\{issue2=\\{1.2=1\\}, issue1=\\{\"i1v1\"=1\\}\\}\\]");
+	}
+
+	@Test(expected = NullPointerException.class)
+	public void smokeNullTest() {
+		new FrequencyOpponentModel(null);
+	}
+
+	@Test
+	public void smokeTest() {
+		new FrequencyOpponentModel(domain);
+	}
+
+	@Test
+	public void testEmptyModel() {
+		FrequencyOpponentModel oppModel = new FrequencyOpponentModel(domain);
+		assertEquals(BigDecimal.ONE, oppModel.getUtility(bid1));
+		assertEquals(BigDecimal.ONE, oppModel.getUtility(bid2));
+	}
+
+	@Test
+	public void testUpdate() {
+		OpponentModel oppModel = oppModel1.update(bid1);
+		assertTrue(BigDecimal.ONE.compareTo(oppModel.getUtility(bid1)) == 0);
+		assertTrue(BigDecimal.ZERO.compareTo(oppModel.getUtility(bid3)) == 0);
+		// bid2 has 1 of 2 issue values same as bid1.
+		assertTrue(HALF.compareTo(oppModel.getUtility(bid2)) == 0);
+	}
+
+	@Test
+	public void testUpdate2() {
+		// bid1 and bid2 both want I1V1. They differ on the number value.
+		// bid3 wants I1V2 but does have the number value from bid2
+		OpponentModel oppModel = oppModel1.update(bid1).update(bid2);
+		assertTrue(new BigDecimal("0.75").compareTo(oppModel.getUtility(bid1)) == 0);
+		assertTrue(new BigDecimal("0.75").compareTo(oppModel.getUtility(bid2)) == 0);
+		assertTrue(new BigDecimal("0.25").compareTo(oppModel.getUtility(bid3)) == 0);
+	}
+
+}
Index: bidspace/src/test/java/geniusweb/bidspace/IntervalTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/IntervalTest.java	(revision 52)
+++ 	(revision )
@@ -1,118 +1,0 @@
-package geniusweb.bidspace;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
-
-import java.math.BigDecimal;
-import java.util.Arrays;
-import java.util.List;
-
-import org.junit.Test;
-
-import tudelft.utilities.junit.GeneralTests;
-
-public class IntervalTest extends GeneralTests<Interval> {
-
-	private static final BigDecimal ZERO = BigDecimal.ZERO;
-	private static final BigDecimal ONE = BigDecimal.ONE;
-	private static final BigDecimal TWO = BigDecimal.valueOf(2);
-	private static final BigDecimal THREE = BigDecimal.valueOf(3);
-	private static final BigDecimal TEN = BigDecimal.TEN;
-	private static final Interval int1 = new Interval(ZERO, ONE);
-	private static final Interval int1a = new Interval(ZERO, ONE);
-	private static final Interval int2 = new Interval(ONE, TEN);
-	private static final Interval int3 = new Interval(TWO, TEN);
-
-	@Override
-	public List<List<Interval>> getGeneralTestData() {
-		return Arrays.asList(Arrays.asList(int1, int1a), Arrays.asList(int2),
-				Arrays.asList(int3));
-	}
-
-	@Override
-	public List<String> getGeneralTestStrings() {
-		return Arrays.asList("Interval\\[0,1\\]", "Interval\\[1,10\\]",
-				"Interval\\[2,10\\]");
-	}
-
-	@Test
-	public void smokeTest() {
-		new Interval(BigDecimal.ZERO, BigDecimal.ONE);
-	}
-
-	@Test
-	public void smokeTestBad() {
-		Interval i = new Interval(BigDecimal.TEN, BigDecimal.ONE);
-		assertTrue(i.isEmpty());
-	}
-
-	@Test(expected = NullPointerException.class)
-	public void smokeNull1() {
-		new Interval(null, BigDecimal.ZERO);
-	}
-
-	@Test(expected = NullPointerException.class)
-	public void smokeNull2() {
-		new Interval(BigDecimal.ZERO, null);
-	}
-
-	@Test
-	public void testMin() {
-		assertEquals(BigDecimal.ZERO, int1.getMin());
-		assertEquals(BigDecimal.ONE, int2.getMin());
-	}
-
-	@Test
-	public void testMax() {
-		assertEquals(BigDecimal.ONE, int1.getMax());
-		assertEquals(BigDecimal.TEN, int2.getMax());
-	}
-
-	@Test
-	public void containsTest() {
-		assertTrue(int1.contains(BigDecimal.valueOf(0.3)));
-		assertFalse(int1.contains(BigDecimal.valueOf(-0.3)));
-		assertFalse(int1.contains(BigDecimal.valueOf(1.3)));
-
-		assertFalse(int3.contains(ZERO));
-		assertFalse(int3.contains(ONE));
-		assertTrue(int3.contains(TWO));
-		assertTrue(int3.contains(THREE));
-		assertTrue(int3.contains(TEN));
-		assertFalse(int3.contains(BigDecimal.valueOf(10.3)));
-
-	}
-
-	@Test
-	public void testIntersect() {
-		assertEquals(int1, int1.intersect(int1));
-		assertEquals(new Interval(ONE, ONE), int1.intersect(int2));
-		assertTrue(int1.intersect(int3).isEmpty());
-		assertEquals(new Interval(ONE, TWO),
-				new Interval(ZERO, TEN).intersect(new Interval(ONE, TWO)));
-		assertEquals(new Interval(ONE, TWO),
-				new Interval(ONE, TWO).intersect(new Interval(ZERO, TEN)));
-		assertEquals(new Interval(ONE, TWO),
-				new Interval(ZERO, TWO).intersect(new Interval(ONE, TEN)));
-		assertEquals(new Interval(ONE, TWO),
-				new Interval(ONE, TEN).intersect(new Interval(ZERO, TWO)));
-	}
-
-	@Test
-	public void subtractTest() {
-		assertEquals(new Interval(BigDecimal.valueOf(-1), ZERO),
-				int1.subtract(ONE));
-	}
-
-	@Test
-	public void invertTest() {
-		assertEquals(new Interval(BigDecimal.valueOf(-10), ZERO),
-				int1.invert(int2));
-		assertEquals(new Interval(ZERO, TEN), int2.invert(int1));
-		assertEquals(
-				new Interval(BigDecimal.valueOf(-9), BigDecimal.valueOf(8)),
-				int2.invert(int3));
-	}
-
-}
Index: bidspace/src/test/java/geniusweb/bidspace/IssueInfoTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/IssueInfoTest.java	(revision 52)
+++ 	(revision )
@@ -1,68 +1,0 @@
-package geniusweb.bidspace;
-
-import static org.junit.Assert.assertEquals;
-
-import java.math.BigDecimal;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Map;
-import java.util.Set;
-
-import org.junit.Before;
-import org.junit.Test;
-
-import geniusweb.issuevalue.DiscreteValue;
-import geniusweb.issuevalue.DiscreteValueSet;
-import geniusweb.issuevalue.ValueSet;
-import geniusweb.profile.utilityspace.DiscreteValueSetUtilities;
-import geniusweb.profile.utilityspace.ValueSetUtilities;
-
-public class IssueInfoTest {
-
-	private static final String NAME = "name";
-	private static final DiscreteValue VAL1 = new DiscreteValue("v1"),
-			VAL2 = new DiscreteValue("v2"), VAL3 = new DiscreteValue("v3");
-	private static final BigDecimal N03 = new BigDecimal("0.3");
-	private static final BigDecimal N04 = new BigDecimal("0.4");
-	private static final BigDecimal N05 = new BigDecimal("0.5");
-	private static final BigDecimal N06 = new BigDecimal("0.6");
-	private IssueInfo info;
-
-	@Before
-	public void before() {
-		Set<DiscreteValue> issuevalues = new HashSet<>();
-		issuevalues.add(VAL1);
-		issuevalues.add(VAL2);
-		issuevalues.add(VAL3);
-		ValueSet values = new DiscreteValueSet(issuevalues);
-		Map<DiscreteValue, BigDecimal> valueUtils = new HashMap<>();
-		valueUtils.put(VAL1, N03);
-		valueUtils.put(VAL2, N04);
-		valueUtils.put(VAL3, N05);
-		ValueSetUtilities utils = new DiscreteValueSetUtilities(valueUtils);
-		info = new IssueInfo(NAME, values, utils, N06, 6);
-	}
-
-	@Test
-	public void smokeTest() {
-
-	}
-
-	@Test
-	public void testGetExtremeMin() {
-
-		assertEquals(VAL1, info.getExtreme(false));
-		assertEquals(VAL3, info.getExtreme(true));
-	}
-
-	@Test
-	public void getNameTest() {
-		assertEquals(NAME, info.getName());
-	}
-
-	@Test
-	public void getIntervalTest() {
-		assertEquals(new Interval(N03.multiply(N06), N05.multiply(N06)),
-				info.getInterval());
-	}
-}
Index: bidspace/src/test/java/geniusweb/bidspace/PartialSpaceFromUtilityTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/PartialSpaceFromUtilityTest.java	(revision 52)
+++ 	(revision )
@@ -1,32 +1,0 @@
-package geniusweb.bidspace;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.nio.file.Files;
-import java.nio.file.Paths;
-
-import org.junit.Test;
-
-import com.fasterxml.jackson.databind.ObjectMapper;
-
-import geniusweb.profile.Profile;
-import geniusweb.profile.utilityspace.LinearAdditiveUtilitySpace;
-
-public class PartialSpaceFromUtilityTest {
-	private final static ObjectMapper jackson = new ObjectMapper();
-
-	@Test
-	public void createPartialSpaceJobs() throws IOException {
-		String file1 = new String(Files
-				.readAllBytes(Paths.get("src/test/resources/jobs/jobs1.json")));
-		LinearAdditiveUtilitySpace profile = (LinearAdditiveUtilitySpace) jackson
-				.readValue(file1, Profile.class);
-		PartialSpaceFromUtility partial = new PartialSpaceFromUtility(profile,
-				20);
-		System.out.println(jackson.writeValueAsString(partial));
-		int size = partial.getBetter().size();
-		assertTrue(size >= 20); // sometimes 20, sometimes 21
-		assertTrue(size <= 21);
-	}
-}
Index: bidspace/src/test/java/geniusweb/bidspace/pareto/GenericParetoTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/pareto/GenericParetoTest.java	(revision 52)
+++ bidspace/src/test/java/geniusweb/bidspace/pareto/GenericParetoTest.java	(revision 1)
@@ -2,11 +2,10 @@
 
 import static org.junit.Assert.assertEquals;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.eq;
+import static org.mockito.Matchers.any;
+import static org.mockito.Matchers.eq;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.when;
 
 import java.math.BigDecimal;
-import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
@@ -15,9 +14,8 @@
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 
-import org.junit.Before;
 import org.junit.Test;
 
+import geniusweb.bidspace.pareto.GenericPareto;
 import geniusweb.issuevalue.Bid;
 import geniusweb.issuevalue.DiscreteValue;
@@ -29,5 +27,4 @@
 import geniusweb.issuevalue.ValueSet;
 import geniusweb.profile.PartialOrdering;
-import geniusweb.profile.Profile;
 
 public class GenericParetoTest {
@@ -42,17 +39,13 @@
 	private static final Map<String, ValueSet> issues = new HashMap<>();
 
-	private static ValueSet values1;
-	private static ValueSet values2;
+	private static final ValueSet values1;
+	private static final ValueSet values2;
 	private static final BigDecimal TWO = new BigDecimal("2");
 	private static final BigDecimal THREE = new BigDecimal("3");
 
-	private static Domain domain;
+	private static final Domain domain;
 	private static Bid bid1, bid2, bid3;
 
-	private PartialOrdering profile1, profile2, profile3;
-	private GenericPareto pareto;
-
-	@Before
-	public void before() {
+	static {
 		Collection<DiscreteValue> discretevalues1 = new LinkedList<>();
 		discretevalues1.add(I1V1);
@@ -77,17 +70,13 @@
 		bid3 = new Bid(issuevalues);
 
-		profile1 = mock(PartialOrdering.class);
-		profile2 = mock(PartialOrdering.class);
-		profile3 = mock(PartialOrdering.class);
-		when(profile1.getDomain()).thenReturn(domain);
-		when(profile2.getDomain()).thenReturn(domain);
-		when(profile3.getDomain()).thenReturn(domain);
-
-		pareto = new GenericPareto(Arrays.asList(profile1, profile2));
-
 	}
 
 	@Test
 	public void genericParetoTest() {
+		PartialOrdering profile1 = mock(PartialOrdering.class);
+		PartialOrdering profile2 = mock(PartialOrdering.class);
+
+		when(profile1.getDomain()).thenReturn(domain);
+		when(profile2.getDomain()).thenReturn(domain);
 
 		// fefault: there is no preference at all, all isPreferredOrEqual
@@ -103,4 +92,9 @@
 	@Test
 	public void genericParetoTest1() {
+		PartialOrdering profile1 = mock(PartialOrdering.class);
+		PartialOrdering profile2 = mock(PartialOrdering.class);
+
+		when(profile1.getDomain()).thenReturn(domain);
+		when(profile2.getDomain()).thenReturn(domain);
 
 		// both prefer bid1 over any other bid.
@@ -109,4 +103,7 @@
 		when(profile2.isPreferredOrEqual(eq(bid1), any(Bid.class)))
 				.thenReturn(true);
+
+		List<PartialOrdering> profiles = Arrays.asList(profile1, profile2);
+		GenericPareto pareto = new GenericPareto(profiles);
 
 		Collection<Bid> points = pareto.getPoints();
@@ -117,4 +114,9 @@
 	@Test
 	public void genericParetoTest2() {
+		PartialOrdering profile1 = mock(PartialOrdering.class);
+		PartialOrdering profile2 = mock(PartialOrdering.class);
+
+		when(profile1.getDomain()).thenReturn(domain);
+		when(profile2.getDomain()).thenReturn(domain);
 
 		// both prefer bid2 over any other bid.
@@ -123,4 +125,6 @@
 		when(profile2.isPreferredOrEqual(eq(bid2), any(Bid.class)))
 				.thenReturn(true);
+		List<PartialOrdering> profiles = Arrays.asList(profile1, profile2);
+		GenericPareto pareto = new GenericPareto(profiles);
 
 		Collection<Bid> points = pareto.getPoints();
@@ -132,4 +136,10 @@
 	@Test
 	public void genericParetoTest3() {
+		PartialOrdering profile1 = mock(PartialOrdering.class);
+		PartialOrdering profile2 = mock(PartialOrdering.class);
+
+		when(profile1.getDomain()).thenReturn(domain);
+		when(profile2.getDomain()).thenReturn(domain);
+
 		// profile1 prefers bid1, profile2 prefers bid2.
 		// now neither bid1 nor bid2 are dominating each other
@@ -139,4 +149,6 @@
 		when(profile2.isPreferredOrEqual(eq(bid2), any(Bid.class)))
 				.thenReturn(true);
+		List<PartialOrdering> profiles = Arrays.asList(profile1, profile2);
+		GenericPareto pareto = new GenericPareto(profiles);
 
 		Collection<Bid> points = pareto.getPoints();
@@ -147,4 +159,9 @@
 	@Test
 	public void genericParetoTest4() {
+		PartialOrdering profile1 = mock(PartialOrdering.class);
+		PartialOrdering profile2 = mock(PartialOrdering.class);
+
+		when(profile1.getDomain()).thenReturn(domain);
+		when(profile2.getDomain()).thenReturn(domain);
 
 		// profile1 prefers bid1, profile2 prefers bid2.
@@ -158,4 +175,6 @@
 		when(profile2.isPreferredOrEqual(eq(bid2), any(Bid.class)))
 				.thenReturn(true);
+		List<PartialOrdering> profiles = Arrays.asList(profile1, profile2);
+		GenericPareto pareto = new GenericPareto(profiles);
 
 		Collection<Bid> points = pareto.getPoints();
@@ -164,31 +183,3 @@
 	}
 
-	@Test(expected = IllegalArgumentException.class)
-	public void testNullNotOk() {
-		new GenericPareto(Arrays.asList(profile1, null, profile1));
-	}
-
-	@Test
-	public void testImmutable() {
-		List<PartialOrdering> list = new ArrayList<>(
-				Arrays.asList(profile1, profile2));
-		GenericPareto pareto = new GenericPareto(list);
-		// if we modify the list, the pareto should not change
-		list.add(profile3);
-		assertEquals(2, pareto.getProfiles().size());
-	}
-
-	@Test(expected = UnsupportedOperationException.class)
-	public void testGetParetoAndAdd() {
-		List<Profile> list = pareto.getProfiles();
-		list.add(profile3);
-
-	}
-
-	@Test(expected = UnsupportedOperationException.class)
-	public void testGetPointsAndAdd() {
-		Set<Bid> list = pareto.getPoints();
-		list.add(bid1);
-	}
-
 }
Index: bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoE2Etest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoE2Etest.java	(revision 52)
+++ bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoE2Etest.java	(revision 1)
@@ -19,6 +19,8 @@
 import com.fasterxml.jackson.databind.ObjectMapper;
 
+import geniusweb.bidspace.pareto.GenericPareto;
+import geniusweb.bidspace.pareto.ParetoFrontier;
+import geniusweb.bidspace.pareto.ParetoLinearAdditive;
 import geniusweb.profile.Profile;
-import geniusweb.profile.utilityspace.LinearAdditive;
 import geniusweb.profile.utilityspace.LinearAdditiveUtilitySpace;
 
@@ -36,5 +38,5 @@
 						"src/test/resources/jobs/jobs2.json", 18 },
 				{ "src/test/resources/7issues/7issues1.json",
-						"src/test/resources/7issues/7issues2.json", 557 } });
+						"src/test/resources/7issues/7issues2.json", 351 } });
 	}
 
@@ -59,5 +61,5 @@
 				.readValue(file2, Profile.class);
 
-		List<LinearAdditive> profiles = new LinkedList<>();
+		List<LinearAdditiveUtilitySpace> profiles = new LinkedList<>();
 		profiles.add(profile1);
 		profiles.add(profile2);
Index: bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoPointTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoPointTest.java	(revision 52)
+++ bidspace/src/test/java/geniusweb/bidspace/pareto/ParetoPointTest.java	(revision 1)
@@ -4,5 +4,5 @@
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
-import static org.mockito.ArgumentMatchers.eq;
+import static org.mockito.Matchers.eq;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.when;
@@ -10,13 +10,13 @@
 import java.math.BigDecimal;
 import java.util.Arrays;
-import java.util.HashMap;
-import java.util.Map;
+import java.util.HashSet;
 
 import org.junit.Before;
 import org.junit.Test;
 
+import geniusweb.bidspace.pareto.ParetoPoint;
 import geniusweb.issuevalue.Bid;
 import geniusweb.issuevalue.Value;
-import geniusweb.profile.utilityspace.LinearAdditive;
+import geniusweb.profile.utilityspace.LinearAdditiveUtilitySpace;
 
 public class ParetoPointTest {
@@ -26,6 +26,7 @@
 	private static final BigDecimal D0_4 = BigDecimal.valueOf(0.4);
 	private static final BigDecimal D0_5 = BigDecimal.valueOf(0.5);
-	private final LinearAdditive space1 = mock(LinearAdditive.class),
-			space2 = mock(LinearAdditive.class);
+	private final LinearAdditiveUtilitySpace space1 = mock(
+			LinearAdditiveUtilitySpace.class),
+			space2 = mock(LinearAdditiveUtilitySpace.class);
 	private final Bid bid11 = mock(Bid.class), bid12 = mock(Bid.class),
 			bid21 = mock(Bid.class), bid22 = mock(Bid.class);
@@ -86,15 +87,21 @@
 	@Test
 	public void mergeTest() {
+		// partial bid 020_010 has value 0.2 for issue 2 in space1 and 0.1 for
+		// issue 2 in space2.
+		Bid partialbid020_010 = mock(Bid.class),
+				partialbid102_301 = mock(Bid.class);
+		// merged this should be a bid 122_311 so it has utilities
+		// 1+2+2=0.5 in space1 and 3+1+1=0.5 in space2
+
+		when(partialbid020_010.getIssues())
+				.thenReturn(new HashSet<String>(Arrays.asList("issue2")));
+		when(partialbid102_301.getIssues()).thenReturn(
+				new HashSet<String>(Arrays.asList("issue1", "issue3")));
+
 		Value value1 = mock(Value.class), value2 = mock(Value.class),
 				value3 = mock(Value.class);
-		// partial bid 020_010 has value 0.2 for issue 2 in space1 and 0.1 for
-		// issue 2 in space2.
-		Bid partialbid020_010 = new Bid("issue2", value2);
-		Map<String, Value> vals2 = new HashMap<>();
-		vals2.put("issue1", value1);
-		vals2.put("issue3", value3);
-		Bid partialbid102_301 = new Bid(vals2);
-		// merged this should be a bid 122_311 so it has utilities
-		// 1+2+2=0.5 in space1 and 3+1+1=0.5 in space2
+		when(partialbid020_010.getValue(eq("issue2"))).thenReturn(value2);
+		when(partialbid102_301.getValue(eq("issue1"))).thenReturn(value1);
+		when(partialbid102_301.getValue(eq("issue3"))).thenReturn(value3);
 
 		when(space1.getUtility(eq(partialbid020_010))).thenReturn(D0_2);
@@ -110,4 +117,11 @@
 		ParetoPoint p = p1.merge(p2);
 		Bid bid = p.getBid();
+		assertEquals(
+				new HashSet<String>(
+						Arrays.asList("issue1", "issue2", "issue3")),
+				bid.getIssues());
+		assertEquals(value1, bid.getValue("issue1"));
+		assertEquals(value2, bid.getValue("issue2"));
+		assertEquals(value3, bid.getValue("issue3"));
 		assertEquals(D0_5, p.getUtilities().get(0));
 		assertEquals(D0_5, p.getUtilities().get(1));
Index: bidspace/src/test/java/geniusweb/bidspace/pareto/PartialParetoTest.java
===================================================================
--- bidspace/src/test/java/geniusweb/bidspace/pareto/PartialParetoTest.java	(revision 52)
+++ bidspace/src/test/java/geniusweb/bidspace/pareto/PartialParetoTest.java	(revision 1)
@@ -16,9 +16,10 @@
 import org.junit.Test;
 
+import geniusweb.bidspace.pareto.PartialPareto;
 import geniusweb.issuevalue.Bid;
 import geniusweb.issuevalue.Domain;
 import geniusweb.issuevalue.Value;
 import geniusweb.issuevalue.ValueSet;
-import geniusweb.profile.utilityspace.LinearAdditive;
+import geniusweb.profile.utilityspace.LinearAdditiveUtilitySpace;
 
 public class PartialParetoTest {
@@ -30,6 +31,7 @@
 	private static final BigDecimal D0_5 = BigDecimal.valueOf(0.5);
 
-	private final LinearAdditive space1 = mock(LinearAdditive.class),
-			space2 = mock(LinearAdditive.class);
+	private final LinearAdditiveUtilitySpace space1 = mock(
+			LinearAdditiveUtilitySpace.class),
+			space2 = mock(LinearAdditiveUtilitySpace.class);
 
 	private Domain domain = mock(Domain.class);
