Klaros Custom Reports retrieve corresponding TestStep for TestStepResult

Fabian Tietz, modified 10 Years ago.

Klaros Custom Reports retrieve corresponding TestStep for TestStepResult

Youngling Posts: 9 Join Date: 8/9/13 Recent Posts
For a custom report, i need the Action/ExpectedResult/Precondition/Postcondition
for the teststep belonging to a failed TestStepResult. What ts the preferred way to retrieve that,
since the TestStepResult has no getTestStep Method?

Is there any documentation for the database backend?
thumbnail
Torsten Stolpmann, modified 10 Years ago.

RE: Klaros Custom Reports retrieve corresponding TestStep for TestStepResul

Jedi Council Member Posts: 755 Join Date: 2/12/09 Recent Posts
Hi Fabian,

you may this information at the test case which is referenced by the test case step result (KlarosTestCaseStepResult.getTestCase()) using the same index as in the step result list (KlarosTestCase.getTestCaseSteps().getAction() etc.).

I opened an enhancement issue (KLAROS-1924) to make this information directly available at the KlarosTestCaseStepResult object, as the current method is indeed too cumbersome .

We do not document database structures as they have and will change over time. We support the API instead.

Hope this helps,

Torsten
Fabian Tietz, modified 10 Years ago.

RE: Klaros Custom Reports retrieve corresponding TestStep for TestStepResul

Youngling Posts: 9 Join Date: 8/9/13 Recent Posts
By DB Structure, i was referring to the areas which can be queried by using "context.executeQuery" from the scripting API, not internal database structure. It would be nice to get an overview on possible select statements here.

For the record (in case someone else needs this):

Accessing TestStepContent works by using:

<ui:repeat value="#{tcr.getStepResults().toArray()}" var="tsr" >
....
<p:text value="#{tcr.getTestCase().getTestCaseSteps().get(ptcr.getStepResults().indexOf(tsr)).getAction()}" />
....

(tcr==TestCaseResult)
thumbnail
Torsten Stolpmann, modified 10 Years ago.

RE: Klaros Custom Reports retrieve corresponding TestStep for TestStepResul (Answer)

Jedi Council Member Posts: 755 Join Date: 2/12/09 Recent Posts
Hi Fabian,

the Model API lists the available entities for KlarosContext.executeQuery().

Technically this is a slightly modified subset of the Hibernate Query Language (HQL), which may help if you are familiar with its concepts.

Regards,

Torsten
thumbnail
Torsten Stolpmann, modified 10 Years ago.

RE: Klaros Custom Reports retrieve corresponding TestStep for TestStepResul

Jedi Council Member Posts: 755 Join Date: 2/12/09 Recent Posts
Hi Fabian,

The enhancement request KLAROS-1924 is now implemented towards the upcoming Klaros-Testmanagement 3.8.1 release.

Thanks for pointing this out!

Regards,

Torsten