Highlighted
pakumar Absent Member.
Absent Member.
777 views

How we can update manual tests status programatically

Jump to solution

We have a Automation Framework that we integrated with the SilkCentral Test using Process Executor. After completion of this test we will get the Report file from our Automation and we will be able to get that result file in Files tab of that particular Execution Plan Run. In this automation we are running around 950 test cases.

 

Now we are planning to map each test case result from the report file with the manual tests that we have already created.   Is there any way that we can take here?

 

0 Likes
1 Solution

Accepted Solutions
Micro Focus Expert
Micro Focus Expert

RE: How we can update manual tests status programatically

Jump to solution
I got your issue 🙂

You have one automated test in Silk Central that triggers 950 tests to be executed - and instead of just having one "trigger"-test in Silk Central you want to see the "real" 950 tests with their status inside Silk Central. For that reason you created 950 manual tests which you now want to update based on the result of your 950 tests.

Unfortunately there is NO functionality to update manual tests programmatically.

BUT - we have two other options how to solve that:

Option 1 - External Execution (as described above; part of Silk Central 19.0)
(1) Convert your 950 manual tests to any automation type (as external execution works for automated tests only)
(2) Add those 950 automated tests to an execution plan
(3) Enable "External Execution" in deployment options
(4) Add your existing "DummyTest" Process Executor test as Setup test
(5) Add some execution server to run the setup test
(6) Start the execution
--> Your automation will be started because of the setup test
--> You have an execution plan run started with 950 tests that can now be updated with the new REST API. So you would need to write a parser for your HTML report to update the tests in Silk Central accordingly.

Option 2 - Test Package (output.xml)
If you search for "Test Package" in Silk Central's help you should find all the necessary information. In the end the test package functionality was added to Silk Central to provide visibility for complex test structures (e.g. JUnit suites) with minimal configuration effort.
In your case it should be possible to keep your process executor test - the only change needed is that the execution of your 950 tests has to create a so called "output.xml".
Once a valid "output.xml" is available you just have to right click your process executor test and execute the "Convert to Test Package" action - this results in transforming your single process executor test in a whole test structure as described by your "output.xml". So you will see all the 950 tests in Silk Central automatically.
This created structure is also maintained with each new execution - so if you add tests they will be added. If tests are removed they are not automatically removed but you can "Cleanup" your test package with an according action.

Hope one of the two options meets your needs!

Regards,
Florian
Product Owner - Silk
4 Replies
Micro Focus Expert
Micro Focus Expert

RE: How we can update manual tests status programatically

Jump to solution
Hi,

do I understand that correctly that you created those manual test cases in Silk Central to actually represent your automated tests and have the results collected in Silk Central?

For this scenario the upcoming Silk Central 19.0 (GA end of June) will provide an "external execution"-mode together with a new REST API to update automated test execution runs.

(1) You create your automated test "stubs" in Silk Central
(2) You create an execution plan, assign the automated test "stubs" and trigger the execution in "external execution" mode - this means the execution is waiting to receive results from "external", meaning the automated tests are not executed via Silk Central's execution servers but in your execution environment.
(3) You can query all information about this "external" execution plan run with the new REST API - so you will know all the tests that should be executed, all the parameters, options, etc. - this allows you to pass this information on to your execution environment.
(4) As early as you have results available by running the tests in your execution environment you can use the new REST API to update/finish the "external" execution plan run in Silk Central. The REST API also supports updating single test runs (so you can show execution progress in Silk Central), adding attachments, finishing the execution plan run, etc.

Is this matching what you were looking for?

Regards,
Florian
Product Owner - Silk
pakumar Absent Member.
Absent Member.

RE: How we can update manual tests status programatically

Jump to solution
Sorry but I am not sure whether you got my issue, please correct me if I misunderstood you response. 🙂

I explain you my scenario, on cmd we use Automation.exe <TestParameters> to run our automation that is having 950 test cases and it generates a HTML report. So to integrate with SilkCentral we created one Process Executor test say "DummyTest" and passed above command.
Then we created Execution plan say "DummyPlan" and assigned only "DummyTest" to the plan, after running DummyPlan that having only one test case we are getting our HTML report file that is having a results of 950 test cases. We can able to access that report in Files tab of the "DummyPlan" run.
Now we have a container say "TestCaseContainer" where these 950 test cases are there as a manual tests.

We want to change the status of those 950 manual test cases that are under container "TestCaseContainer" after getting the HTML result report of "DummyPlan" that we ran earlier.

Hope I am able to explain my requirement. 🙂
0 Likes
Micro Focus Expert
Micro Focus Expert

RE: How we can update manual tests status programatically

Jump to solution
I got your issue 🙂

You have one automated test in Silk Central that triggers 950 tests to be executed - and instead of just having one "trigger"-test in Silk Central you want to see the "real" 950 tests with their status inside Silk Central. For that reason you created 950 manual tests which you now want to update based on the result of your 950 tests.

Unfortunately there is NO functionality to update manual tests programmatically.

BUT - we have two other options how to solve that:

Option 1 - External Execution (as described above; part of Silk Central 19.0)
(1) Convert your 950 manual tests to any automation type (as external execution works for automated tests only)
(2) Add those 950 automated tests to an execution plan
(3) Enable "External Execution" in deployment options
(4) Add your existing "DummyTest" Process Executor test as Setup test
(5) Add some execution server to run the setup test
(6) Start the execution
--> Your automation will be started because of the setup test
--> You have an execution plan run started with 950 tests that can now be updated with the new REST API. So you would need to write a parser for your HTML report to update the tests in Silk Central accordingly.

Option 2 - Test Package (output.xml)
If you search for "Test Package" in Silk Central's help you should find all the necessary information. In the end the test package functionality was added to Silk Central to provide visibility for complex test structures (e.g. JUnit suites) with minimal configuration effort.
In your case it should be possible to keep your process executor test - the only change needed is that the execution of your 950 tests has to create a so called "output.xml".
Once a valid "output.xml" is available you just have to right click your process executor test and execute the "Convert to Test Package" action - this results in transforming your single process executor test in a whole test structure as described by your "output.xml". So you will see all the 950 tests in Silk Central automatically.
This created structure is also maintained with each new execution - so if you add tests they will be added. If tests are removed they are not automatically removed but you can "Cleanup" your test package with an according action.

Hope one of the two options meets your needs!

Regards,
Florian
Product Owner - Silk
Shankara Narayanan
New Member.

Re: RE: How we can update manual tests status programatically

Jump to solution

I have tried the first way by having one test setup test case ( which will trigger entire test suite) and the real cases as assigned test cases. Everything looks good, test cases are getting triggered.

But after the execution, when I tried to update the results through REST API, I get an error saying 

{
  "status": 403,
  "message": "Only external runs can be updated via API"
}

How to overcome? Apart from starting the execution through REST API? I would like to start the execution manually through the Play button and then see the results gets updated automatically through REST API which is already coded in the automation framework.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.