Forum Discussion

Duess's avatar
Duess
Occasional Contributor
6 years ago
Solved

Get & Set Cookie - Advice/Best Approach Assistance

Been racking my brain with documentation for days on this one and need to move on from it or find different ways to achieve this. 

 

So our web application gives the logged-in user a few unique identifiers post login that are set in the header.  ASP.Net, {company specific UID}, __RequestVerificationToken.  I don't want to pretend that I understand why we need all of them, but I have compared session headers and these are the ones I need to get & hold while the test(s) run [while keeping browser window open]. 

 

Test Scenario

 - Login (user with specific permissions)

 - Navigate to pages throughout application

 - Verify each page responds with a 200 Response

 

I have read all the SmartBear documentation on helper objects aqHttp, aqHttpRequest, aqHttpResponse, XMLHttpRequest, etc. and I just cannot nail it down for getting it accomplished.    

TestComplete ver.12.50.4142.7

 

Anyone out there that has accomplished something similar or can lend advice?  

Thanks in advance. 

 

-D

  • Sounds like you're trying to test things at the API level, and while Test Complete does off some API testing functionality, you would be much better off with ReadyAPI / SoapUI for something like this. 

4 Replies

  • cunderw's avatar
    cunderw
    Community Hero

    Sounds like you're trying to test things at the API level, and while Test Complete does off some API testing functionality, you would be much better off with ReadyAPI / SoapUI for something like this. 

    • Duess's avatar
      Duess
      Occasional Contributor

      cunderw 

      Thank you for the reply.  I was thinking that may be the issue.  I hesitated going that aproach at first because I thought there may be some work around or some of the API testing processes in TC.  

      I already have SOAPUI installed on machine and am going to go look into this now. Appreciate the reply and suggested approach. 

       

  • AlexKaras's avatar
    AlexKaras
    Champion Level 3

    Hi,

     

    cunderw is correct that TestComplete provides only basic support for API testing and you should be aware that this will be pure coded solution.

    Tha answer whether or not it is worth to try with TestComplete significantly depends on what authentication type is implemented in your web application. The things are easy and quite straightforward in case of basic authentication. Though in the case of NTLM and other types the things are (much) more complex.

    • Duess's avatar
      Duess
      Occasional Contributor

      Thanks AlexKaras this is great information. I am going to look more into it and play around with SoapUI to accomplsh this portion of my testing. 

      Appreciate responses and advice.