QTP business component and datatable saved in QC in resource module (2833 Views)
Reply
Honored Contributor
Vladimir Skrbek
Posts: 2,095
Registered: ‎03-12-2008
Message 1 of 7 (2,833 Views)

QTP business component and datatable saved in QC in resource module

[ Edited ]

Hi does anybody know how to use datatable from QC in QTP for business component?

 

When I open component in QTP then I can use libraries or object repository saved in QC in Resource module but I cannot use any datatable saved in QC in resource module in teh same manner as for QTP test.

 

Thank you for answer

------------------------------------------------------------------------------------------------------------------------------
PS. This thread has been moved from Business Process Validation Support and News Forum to Unified Functional Testing (formerly QTP) News and Support Forum - Forum Moderator

Respected Contributor
Erodabasi Atacan
Posts: 588
Registered: ‎01-16-2008
Message 2 of 7 (2,814 Views)

Re: QTP business component and datatable saved in QC in resource module

Hi Vladimir,

do you get error message? For Scripted Component you schould have problems. How do you use the data table? Do you import the table via Script or do you link the data table in the setting (File --> Settings --> (Data Table) Other Location ?

 

A.E.

Respected Contributor
Erodabasi Atacan
Posts: 588
Registered: ‎01-16-2008
Message 3 of 7 (2,813 Views)

Re: QTP business component and datatable saved in QC in resource module

Sorry,

I mean under File --> Settings --> Recources --> Other location (Radio button)

Advisor
BenV
Posts: 16
Registered: ‎02-04-2009
Message 4 of 7 (2,730 Views)

Re: QTP business component and datatable saved in QC in resource module

[ Edited ]

I have a similar question.  I am attempting to use a data table in a Scripted Business Component but it only seems to read/loop the first row in the table and ignores the rest.  In regulard scripted tests (i.e. not Business Components it would always loop through all rows in the data table.  

 

Is this possible with Business Components or do I have to use parameters and iterations in QC?

 

FYI

Both the File --> Settings --> Recources --> Other location (Radio button) option (as suggested above) and the Test Flow --> Action Call Properties --> Run All Rows (Radio button) are specific to regular automated tests and do not apply to Business Components.  Can't find a way to force it to run more than a single row in the data table.

Advisor
PhillipHilgert
Posts: 18
Registered: ‎07-25-2011
Message 5 of 7 (2,646 Views)

Re: QTP business component and datatable saved in QC in resource module

Vladimir,

 

do you mean the iterations grid in QC for BPT components?

 

If so, you refer to the iteration grid columns as input parameters (which can be defined in the component settings.  From QTP:  File -> Settings -> Parameters).

 

For iterations, go to the test script in QC, right-click on the component to identify which iteration rows are to be run.  Components can be grouped so that they will all be executed before running the next iteration of data.

 

 - Phillip

 


Vladimir Skrbek wrote:

Hi does anybody know how to use datatable from QC in QTP for business component?

When I open component in QTP then I can use libraries or object repository saved in QC in Resource module but I cannot use any datatable saved in QC in resource module in teh same manner as for QTP test.

 

Thank you for answer




Occasional Visitor
Karnan
Posts: 1
Registered: ‎03-20-2013
Message 6 of 7 (2,163 Views)

Re: QTP business component and datatable saved in QC in resource module

Hi,

 

Based on my experiance; QC does not allow any data/file manipulation at server side. We should download from QC to local folder then perform the actions and upload back to the QC.

 

My recommandation would be; attach that excel as part of test plan and download the attachment at run time (through QCUtil object).

Respected Contributor
Martin Sander
Posts: 486
Registered: ‎10-20-2008
Message 7 of 7 (2,008 Views)

Re: QTP business component and datatable saved in QC in resource module

Hi

 

Yes you can use Datasheets stored in Test Resources in ALM for Business Process Tests, its just different to the way they are used for QTP.

 

First thing to understand is that the Datasheet defines your RunTime parameters for your Business Process Test.

 

So, you define the Parameters in your Business Component. When you add the Component to a Test you define how the parameter is to be used - not at all ( blank entry ); Fixed value; linked to a previous steps output parameter; or as a Runtime parameter ( defined as {parameter} ). ALM will auto suggest a parameter name but you can override this to any name you want - so one more relevant to your testing.

The Parameters Tab should reflect those parameters which you have defined as runtime parameters - any which you don't need you should delete. Also, click on the 'Show Test Parameters Promotion Status' button ( under the Test Script Tab ) to ensure that all parameters have been configured correctly.

Next create the Datasheet with the Runtime Parameters you want to use for the Test. This could contain one or multiple lines. Load it up to the Test Resources module

In the Test Plan, create a Test Configuration and then on the Data tab select the Dynamic Option. This will then give you the option to Override the assigned Datasheet with another from the Test Resources Module. Under the Data Resources settings button you can specify whether 1 row, a selection of rows, or all rows are to be run

 

Hope this helps

 

Thanks

 

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.