Ignore:
Timestamp:
08/05/20 09:42:15 (4 years ago)
Author:
bart
Message:

Added BOA support, some bug fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • opponentmodel/src/test/java/geniusweb/profile/opponentmodel/FrequencyOppModelTest.java

    r18 r20  
    8787                bid3 = new Bid(issuevalues);
    8888
    89                 oppModel1 = new FrequencyOpponentModel(domain);
    90                 oppModel1b = new FrequencyOpponentModel(domain);
    91                 oppModel2 = new FrequencyOpponentModel(domain2);
    92                 oppModel3 = new FrequencyOpponentModel(domain3);
     89                oppModel1 = new FrequencyOpponentModel().with(domain, null);
     90                oppModel1b = new FrequencyOpponentModel().with(domain, null);
     91                oppModel2 = new FrequencyOpponentModel().with(domain2, null);
     92                oppModel3 = new FrequencyOpponentModel().with(domain3, null);
    9393                oppModel4 = oppModel3.with(new Offer(other, bid1), progress);
    9494
     
    113113        @Test(expected = NullPointerException.class)
    114114        public void smokeTestNull() {
    115                 new FrequencyOpponentModel(null);
     115                new FrequencyOpponentModel().with((Domain) null, null);
    116116        }
    117117
    118118        @Test
    119119        public void smokeTest() {
    120                 new FrequencyOpponentModel(domain);
     120                new FrequencyOpponentModel().with(domain, null);
    121121        }
    122122
    123123        @Test
    124124        public void testEmptyModel() {
    125                 FrequencyOpponentModel oppModel = new FrequencyOpponentModel(domain);
     125                FrequencyOpponentModel oppModel = new FrequencyOpponentModel()
     126                                .with(domain, null);
    126127                assertEquals(BigDecimal.ONE, oppModel.getUtility(bid1));
    127128                assertEquals(BigDecimal.ONE, oppModel.getUtility(bid2));
     
    153154        }
    154155
     156        @Test
     157        public void testPartialBidUpdate() {
     158                FrequencyOpponentModel oppModel = oppModel1.with(new Offer(other, bid1),
     159                                progress);
     160                Bid partialbid = new Bid(ISS1, I1V1);
     161                oppModel.with(new Offer(other, partialbid), progress);
     162        }
     163
    155164}
Note: See TracChangeset for help on using the changeset viewer.