SpringBootTest 警告 - ScriptEngineManager

问题描述

我正在为我的应用程序运行一些测试。但是每当我运行它们时,我都会收到以下警告。

ScriptEngineManager providers.next(): javax.script.ScriptEngineFactory: Provider scala.tools.nsc.interpreter.IMain$Factory 无法实例化

它没有产生任何错误,或者至少,就我所见,我仍然想了解是什么导致在我的终端中提示此警告。我的测试可以在下面找到。

@SpringBoottest
public class JpaStockTest {

    @Autowired
    private StockService stockService;

    @Test
    public void comparedStockWithAndWithoutOnlinestock() {
        List<GroupedStock> groupedStocksWithAllStock =
                this.stockService.getGeneralStockWithDate(Collections.singletonList("1LB433-1"),null,null);
        List<GroupedStock> groupedStocksWithOnlinestock =
                this.stockService.getGeneralStockWithDate(Collections.singletonList("1LB433-1"),null);

        long allStock = groupedStocksWithAllStock.stream().mapToLong(GroupedStock::getStock).sum();
        long onlinestock = groupedStocksWithOnlinestock.stream().mapToLong(GroupedStock::getStock).sum();

        assertthat(allStock).isNotEqualTo(onlinestock);

    }
}

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)