【发布时间】:2013-10-21 12:38:22
【问题描述】:
我的测试在从机上运行并连接到主机。在 Jenkins 中配置了一个在从机上运行的作业。所有环境变量都设置在主机上以及从机上。我正在尝试调用 pom 的目标来执行 tesng xml。
错误:
[EnvInject] - Loading node environment variables.
Building remotely on EnterpriseAdaptersNightlySlave in workspace C:\Jenkins\workspace\NetAppAdapterTests
[NetAppAdapterTests] $ C:\apache-maven-3.1.1-bin\apache-maven-3.1.1\bin\mvn.bat -f depot\stats-service\main\QA\pom.xml clean install
Error: Could not find or load main class install
Build step 'Invoke top-level Maven targets' marked build as failure
【问题讨论】:
-
我在 pom 中使用代码:
-
org.apache.maven.plugins maven-surefire-plugin src\testnetappAdapterTestNG. xml listener org.uncommons.reportng.HTMLReporter,org.uncommons.reportng.JUnitXMLReporter true org.uncommons.reportng.title ${com.vmware.vcopsqa.tests.reports.title}值> -
命令 C:\apache-maven-3.1.1-bin\apache-maven-3.1.1\bin\mvn.bat -f depot\stats-service\main\QA\pom.xml在从机上运行良好。
-
您说该命令在从机上运行良好。您是否在运行从属设备的同一用户下尝试过?
-
我尝试以管理员用户身份运行此命令,并且所有环境变量都设置在系统变量下。而且我只在管理员用户下运行 Jenkins 连接器。