コード例 #1
0
  @Test
  public void saveOrUpdateHdcOdds_解析赔率列表为空_将赔率置为空表示错误值() {

    List<HdcOdds> queryHdcList = new ArrayList<>();
    List<HdcOddsHistory> hdcList = new ArrayList<>();
    gamingCompanyHdcDao.saveOrUpdateHdcOdds(
        queryHdcList, hdcList, 1001L, GamingCompany.LiJi.getName());
    verify(hdcOddsRepository).save(isA(HdcOdds.class));
    verifyNoMoreInteractions(hdcOddsRepository);
  }
コード例 #2
0
  @Test
  public void saveOrUpdateHdcOdds_解析出赔率数据但是相比没有变化_不与Repository进行交互() throws Exception {

    List<HdcOdds> queryHdcList = new ArrayList<>();
    HdcOdds hdcOdds = new HdcOdds();
    hdcOdds.setOddsOne("1.86");
    queryHdcList.add(hdcOdds);
    List<HdcOddsHistory> hdcList = new ArrayList<>();
    HdcOddsHistory hdcOddsHistory = new HdcOddsHistory();
    hdcOddsHistory.setOddsOne("1.86");
    hdcList.add(hdcOddsHistory);
    gamingCompanyHdcDao.saveOrUpdateHdcOdds(
        queryHdcList, hdcList, 1001L, GamingCompany.LiJi.getName());
    verifyNoMoreInteractions(hdcOddsRepository);
    verifyNoMoreInteractions(hdcOddsHistoryRepository);
  }