# Command is not working in jenkins

**URL:** <https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317>\
**Category:** Using Jenkins\
**Created:** [May 11, 2023, 6:32am UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317 "2023-05-11T06:32:55Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![vysyaraju](https://avatars.discourse-cdn.com/v4/letter/v/90ced4/32.png) [@vysyaraju](https://community.jenkins.io/u/vysyaraju)\
**Post date:** [May 11, 2023, 6:32am UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/1 "2023-05-11T06:32:55Z")

</div>

Hello Team,

We are using below command to load the testcases but unfortunately testcases are not loading and drivers are not detected and showing count like below in jenkins console output and when we are using same command for another job it is working fine and drivers are detected.

Testcase result: -  
**17:49:39** Test Run Summary **17:49:39** Overall result: Passed **17:49:39** Test Count: 1, Passed: 1, Failed: 0, Warnings: 0, Inconclusive: 0, Skipped: 0

Command which we used in “bat” file:-  
-Exec: OpenCover.Console.exe -target:“nunit3-console.exe” -register:user -targetargs:“"C:\workspace\Tool-projectname-RC-test-TestSuite-ArtNet\TestTools\TestSuite\CI-Scripts\…\Application/bin/x86/Debug/TestSuite.dll" --where:cat=ArtNet --labels=After --workers=1 --agents=1” -output:“C:\workspace\Tool-projectname-RC-test-TestSuite-ArtNet\TestTools\TestSuite\CI-Scripts\…\CodeCoverage\coverageResults.xml”

Note:-When we are using new driver testcases are loading and testcases are running as expected. and when we are using old driver same command is not working and testcases are not loading

---

<div class="post-metadata">

**Author:** ![vysyaraju](https://avatars.discourse-cdn.com/v4/letter/v/90ced4/32.png) [@vysyaraju](https://community.jenkins.io/u/vysyaraju)\
**Post date:** [May 11, 2023, 11:48am UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/2 "2023-05-11T11:48:22Z")

</div>

Can anyone respond on above question please

---

<div class="post-metadata">

**Author:** ![halkeye](https://dub1.discourse-cdn.com/flex013/user_avatar/community.jenkins.io/halkeye/32/8_2.png) [@halkeye](https://community.jenkins.io/u/halkeye)\
**Post date:** [May 11, 2023, 3:59pm UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/3 "2023-05-11T15:59:21Z")

</div>

> [@vysyaraju](#):
>
> Can anyone respond on above question please

people will answer when they are around and have time to answer. Everyone here is volunteering time to help out.

> [@vysyaraju](#):
>
> Test Count: 1, Passed: 1

It seems to say one test ran successfully to me.

I’m not sure how much we can help you with your tests not running in your project. I would recommend looking into how to increase debugging/verboseness with nunit to see what files/paths its trying to run

---

<div class="post-metadata">

**Author:** ![vysyaraju](https://avatars.discourse-cdn.com/v4/letter/v/90ced4/32.png) [@vysyaraju](https://community.jenkins.io/u/vysyaraju)\
**Post date:** [May 12, 2023, 4:15am UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/4 "2023-05-12T04:15:08Z")

</div>

Thanks for the below response

---

<div class="post-metadata">

**Author:** ![vysyaraju](https://avatars.discourse-cdn.com/v4/letter/v/90ced4/32.png) [@vysyaraju](https://community.jenkins.io/u/vysyaraju)\
**Post date:** [May 15, 2023, 1:01pm UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/5 "2023-05-15T13:01:49Z")

</div>

The opencover console.exe is not able to process the parameters like Nunit.exe is not loading the testsuite dll properly for this particular connected device. We need a jenkins help for executing the above query without any issues.

The same query will work for other devices which are running in the jenkins(Please refer to the above description command)

If you have reference documents, please share the links.

---

<div class="post-metadata">

**Author:** ![halkeye](https://dub1.discourse-cdn.com/flex013/user_avatar/community.jenkins.io/halkeye/32/8_2.png) [@halkeye](https://community.jenkins.io/u/halkeye)\
**Post date:** [May 15, 2023, 4:50pm UTC](https://community.jenkins.io/t/command-is-not-working-in-jenkins/7317/6 "2023-05-15T16:50:12Z")

</div>

> [@vysyaraju](#):
>
> We need a jenkins help for executing the above query without any issues.

I don’t think its a jenkins issue. There’s no jenkins error messages. Generally I recommend making sure the commands run fine outside of jenkins, then run them inside of jenkins, and compare the different environments.

* * *

Hi,

This problem sounds like a case of differences between environments. Often caused by a different user, or even a non desktop environment running your agent vs your login session.

I would recommend running a tool to export your environmental variables (`set` in windows, `export` or `printenv` in linux) in both your job and your “command prompt” to see whats different.

Often its something like `HOME` is set different. Or `PATH` has changed since its managed by jenkins agent settings. Or even a license key is missing.

Its usually a good first step.
