cancel
Showing results for 
Search instead for 
Did you mean: 

In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

SOLVED
Highlighted
Occasional Contributor

In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

I added a header in the resource but the test case is not reflecting even after save or refresh.

What is missing here?

1 ACCEPTED SOLUTION

Accepted Solutions
Community Hero

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Hey @deepikatest,

As far as i can remember, even if you use the update/refactor api functionality REST parameter values are NOT persisted (i think it might actually say this somewhere in the help)

It's a little annoying but the way i've handled this before (once the resource or request has been updated with new parms) is to delete the old test step and recreate the test step with the updated parm and value.
I think this is the only way around this.

Cheers,

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

View solution in original post

6 REPLIES 6
Highlighted
Community Hero

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Hey @deepikatest,

There are numerous ways to actually add a header into request.

To help diagnose the issue, could you please provide step by step details on exactly what you did to add the header to the resource please?

Cheers,

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta
Highlighted
Occasional Contributor

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Updated the API under API's by adding below header as highlighted .

Clicked on save, ran the test case.

Observing that newly added header value is not populated in test case.

Also checked by refreshing the project and running the test again but same issue.

What is missing here?

Updated header_API.PNGTestcase_header_not populated.PNG

 

Community Hero

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Hey @deepikatest,

As far as i can remember, even if you use the update/refactor api functionality REST parameter values are NOT persisted (i think it might actually say this somewhere in the help)

It's a little annoying but the way i've handled this before (once the resource or request has been updated with new parms) is to delete the old test step and recreate the test step with the updated parm and value.
I think this is the only way around this.

Cheers,

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta

View solution in original post

Highlighted
Occasional Contributor

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Thanks Richie. 

I believe then it is a defect . 

There could be multiple test steps involved, also they may have different string body and assertions tied to that test step.Each time if we have to delete and add them back , it is laborious process. 

It might not be just headers , could be other examples like adding string body in API itself and then updating it.

 

Highlighted
Community Hero

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

Hey @deepikatest,

I totally agree that its not just REST header parms....its any REST parm (uri/template, query and header and probably matrix too although i've never used matrix parms), its request payloads. i've had projects with hundreds of steps that have had to be updated, so include all the options you tailor on a test step (multiple assertions, REST parms, payloads, etc.) can make this mindbogglingly tedious/timeconsuming.

I need to point out that as annoying as it is like this, it may NOT be a defect if this current behaviour (changes to an existing resource/request not being cascaded to associated test steps) is just an oversight in the coding/requirements and that the functionality was never required to cascade the changes.

If you can find anything in the help to support the case that changes should be cascaded to extant test steps then i'd raise a support ticket (sorry i cant find the link, i'm typing this on my phone) or if it isn't specified in the help you could raise a feature request (via support also). If we got enough upvotes Smartbear may consider adding the functionality in.

Cheers fella,

Rich
if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta
Highlighted
Community Manager

Re: In Ready API 3.0 version, updating the Resources with header but not reflecting in test cases

richie, thank you for providing a workaround for this behavior. 

 

Hi @deepikatest , let me mark the reply by richie as a solution – it provides a good workaround. 

If it doesn’t work for you, I suggest that you submit a support ticket here to work with the R&D team on another solution. Thank you!



Sonya Mihaljova
Community and Education Specialist

 Join SmartBear Connect next April in Boston to meet with software development, API and testing experts from around the world! Get your ticket today!