Retrieve all testcase data with HP QC OTA and Python | Polteq
Share Print E-mail

During my current assignment I was asked if I could provide the data table parameters I used in all my HP Quick Test Pro test cases. Normally this would mean opening QTP, export the data table to an Excel file and open the next test case. Since I had to do this for more than 200+ test cases and they were all on the HP Quality Centre server (which means the test cases would open even slower than usual) I tried to find a faster solution.

I used Python 3.4 and the Quality Center OTA API to access the data directly on the QC server and download it to a local drive.

First the Python class to connect to QC OTA:This class returns the connection object so we can now use it to retrieve all the testcase data in our script.

This class returns the connection object so we can now use it to retrieve all the testcase data in our script.

All the QTP test case data is now stored in the specified folder. Which in my case meant writing a simple script to extract the default.xls, which contained the parameter data, from every folder and rename it.

Please take caution when extracting lots of data from the QC server. Especially the ExtendedStorage can cause the server to crash. Hence my little wait function to keep IT support of my back.

More information

Do you have a question or do you want to make an appointment? Leave your details below and we will contact you as soon as possible. You can also call us:

+31 (0) 33 277 35 22 (The Netherlands)
+32 (0) 16 39 48 04 (Belgium)

    We only use your data to process your question correctly. For more information, read our privacy statement .

    Our core values
    Read more
    Focus
    Focus
    Craftsmanship
    Craftsmanship
    Knowledge sharing
    Knowledge sharing
    Personal touch
    Personal touch
    Local presence
    Local presence
    Sincerity
    Sincerity
    Fun
    Fun
    More
    Deze website is gerealiseerd door Webheads.

    Contact us!