Hi All,
I have a list of test cases which i am executing through orchestrator, is there any activity or code which gives the information about the test case that is running currently say testcase name
Appreciate your response
Hi All,
I have a list of test cases which i am executing through orchestrator, is there any activity or code which gives the information about the test case that is running currently say testcase name
Appreciate your response
@raja.raviraj we could add some message box or log message inside test case to show the test case name which is running
Use log message activity in you code then you can check the logs from orchestrator each step by step
Thanks
Varun
You can use get current job info in your test case then you can get all details about current job(Name,ProcessName,Version etc) which can be logged using a log message activity to display
https://docs.uipath.com/activities/docs/get-current-job-info
cheers
Thanks for the reply, UiPath.Core.Activities is no longer available.It is split into uipath.uiautomation and uipath.system.I dont see this activity in my studio(2022 version).I see something called JobState which is the enum.I verified in both windows-legacy and windows.I am using c# as the language
Thanks for your reply.i dont want to hard code the test case name in every test case that is the tedious job.
This is part of uipath.system.activities not core.activities. Can you tell what issue you are getting?
Okay let me check in c# project also
cheers
Just now check in C# and I am able to see get current job info . Can you please recheck
cheers
@Anil_G Another question related to the same topic, is there anyway i can get the current testsetexecution id.This is the id which is unique for all the test execution and help us to identity the results of the test execution through swagger api.I am getting this ID through the swagger api, the same i need to get while executing the test cases.Please let me know for any clarification
So are you getting the Execution ID from swagger or you want to use the execution ID and get details from swagger?
You can always use orchestrator http request to use api for orchestrator if that is the question
cheers
yes you are rit.I can use orc http request but how do we know what is the executionid for the current execution.
Example:
https://cloud.uipath.com/sdrauipathcloud/DefaultTenant/orchestrator_/odata/TestCaseExecutions
This gives all the testsetexecids but i need the current execution id, using the same once the execution completes ill get the details using the same swagger api and generate test report
Isnât that linked to the job ID as well?
Like for every execution there will be a job id so you can filter with job id and then get the corresponding testexecution id of that job
Let me know if I am missing something here?
cheers
Based on your comment i have to follow below steps to get the testsetexecutionid.
step 1 - Using orchestrator http request get the Running job id first
Ex-â/odata/Jobs?$filter=State eq âRunningâ and HostMachineName eq 'â + Environment.MachineName + â'â
Example output - 687676
step 2 - Again Using orchestrator http request get the testexecutionid for the same job id
Ex-odata/TestCaseExecutions?$orderby=(StartTime) desc&$Filter=Jobid eq 687676
is that rit or is there any other way to get the currently running job id.Please clarify
thanksâŚin some other post i saw this piece of code to get the Job Id
UiPath.Executor.ExecutorManager.Instance.Id.ToString().Looks easier but not working for me. I am using windows + c# combination.Is there any way to get the id using this piece of code.Is there any library i have to download
Please refer below post
Yes I have seen itâŚbut yes there is some issue âŚthat the library is not fully exposed so we are not able to use it directly. so as of now we have the orchestrator api route itselfâŚ
It would give some error on executor always
thank you, ill go with http orchestrtor api
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.