问题记录
IDEA运行测试用例失败,提示Error running Xxxx. Command line is too long.
,说执行命令行太长。
问题解决
修改当前项目下的.idea文件夹里的workspace.xml文件。
步骤:
- 在项目目录下的 .idea 目录里找到 workspace.xml 文件。
- 打开workspace.xml文件找到
<component name="PropertiesComponent">
标签。 - 在
<component name="PropertiesComponent">
标签里面添加一行<property name="dynamic.classpath" value="true" />
,保存退出并重新运行。
参考文献:
1.IDEA在运行测试类的时候报错:Error running ‘test‘: Command line is too long:https://blog.csdn.net/nbxinjian/article/details/124149401