简体   繁体   English

带有jdk11的Eclipse 2018-09声称即使org.junit包也被maven所缺少

[英]Eclipse 2018-09 with jdk11 claims that package org.junit is missing even though it is included by maven

my maven project includes junit and builds including running the tests on the command line with maven. 我的maven项目包括junit和构建,包括使用maven在命令行上运行测试。 However eclipse claims that the package can not be found, I don't understand why eclipse would ignore the dependency. 但是eclipse声称找不到该包,我不明白为什么eclipse会忽略依赖项。

I am depending on version 4.12 of junit 我依赖于junit的4.12版本

右键单击该项目,然后使用Maven > Update Project...以获取与pom.xml同步的构建路径设置。

Please check the version of junit in the pom.xml. 请在pom.xml中检查junit的版本。 The 3.x version is programmed and 4.x is the annotation method. 已编程3.x版本,而4.x是注释方法。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM