cancel
Showing results for 
Search instead for 
Did you mean: 

Renamed endpoints

SOLVED
Highlighted
Occasional Contributor

Renamed endpoints

I use ready api and developed a composite project to test rest api. I have added multiple endpoints under Apis. Then I renamed the service(APIs navigator tree) as similar to the test suite that I used the endpoint.
https://support.smartbear.com/readyapi/docs/_images/apis/organize/rest-structure.png

Then I committed the code to git and when imported this project by someone , endpoints that named similar to the test suites are missing. Could I solve this problem?.
Tags (1)
2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Occasional Contributor

Re: Renamed endpoints - ready api

There are some APIs I did not rename as similar to the test suite name. These APIs and test cases remain as it is.

View solution in original post

Highlighted
Community Hero

Re: Renamed endpoints - ready api

Hey @Manijem,

Before the commit/merge are you ensuring you are saving after the rename before you do the push? I know youd expect a save to occur as part of the push but id hit the save first just to be sure. I gotta admit, the fact that the renamed apis are disappearing makes me think youve found a defect, but we need to be sure.

As an exercise to determine exactly the boundaries of your issue, id try the following tests.

1. Rename apis, create tests against renamed APIs, HIT SAVE! then close down ReadyAPI! (without the commit/merge) and relaunch ReadyAPI! and check the state of the renamed apis.
Are the APIs still present?
Are the associated test cases still present?
Do the commit/merge
Pull the latest code back into ReadyAPI!.
Check the state of the renamed APIs/associated tests....are they both still present?

2. Create APIs, create tests, save, then commit/merge.
Pull the merged version back
Rename APIs, create a new test against renamed API, save, then commit/merge.
Pull the latest version back.
Check the state of the renamed APIs/associated tests....are they both still present?
Are the tests that were created against the API (before it was renamed) still present?

According to the detail youve provided, youre doing the renaming of the APIs via API Navigator rather than via the Projects tab. Can you follow my instructions above, but this time do the renaming of the APIs via the Projects tab rather than renaming via the API Navigator frame? (Dont forget to hit Save!).

I'm ezpecially interested in the tests associated with the API and whether they are present after youve pulled from git. The tests are child objects of the APIs, so you cant delete the API without delete the tests also, so if it is a defect it sounds like bit of a whopper.

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

8 REPLIES 8
Highlighted
Community Hero

Re: Renamed endpoints

Hey @Manijem,

Just to clarify a couple of points:

Q1. You created some new requests and subsequently renamed the service objects before you hit save, then did a push and merged your updates into the existing git repo and after this you did a pull and the previously renamed services had the original naming (the same name as when the services were created)?

Q2. You say the naming is incorrect in the API Navigator view. Are the names incorrect when viewing via the 'Projects' tab (top right of the window next to the 'SoapUI Pro' tab)?

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
Occasional Contributor

Re: Renamed endpoints - ready api

Thank you very much for the answer. Actually, I am still new to this tool. I just added api endpoints to APIs and once they are populated under Apis, I renamed the source part. Once I completed the test cases , just pushed the code. I never saved anything by clicking on save. But some renamed endpoints are populated under Apis. As per my understanding,
In the local workspace, I can't see the missing folders and it seems that merging with folder with same name of test suite folders.
Tags (2)
Highlighted
Occasional Contributor

Re: Renamed endpoints - ready api

If this explanation is not clear, please mention it. Then I can explain it again
Highlighted
Community Hero

Re: Renamed endpoints - ready api

Hey @Manijem,

I think i understood some of it but if you could clarify a little further it.can only help people reading about the issue.

TA

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: Renamed endpoints - ready api

Thank you very much for your answers. Actually, I have followed the same steps that I mentioned in the below. As per the documentation, it may be wrong. But I just try to fix the mistake.

(Ready api latest version I used )
1. I created a composite project
2. Then I got two sections like APIs and etc.
3. I selected APIs and right click - add api.
4. Select endpoints tab .
5. Select http method and enter only service location.
Eg : http://dummy.restapiexample.com

Url : http://dummy.restapiexample.com/api/v1/employees

6. Then, navigate environments editor panel.
7. Here, click rest service tab, then I can see the added service as name.
8. Against the service name , under the endpoint column , I added /api/v1/employees

(Eg : This is url
http://dummy.restapiexample.com/api/v1/employees)

9. Again, in the APIs navigation tree, I renamed this "http://dummy.restapiexample.com" as similar to the test suite name that I am going to create. Renamed like employee.

10. Then, i created test suite and given the like employee and added test steps. Linked to added APIs.

11. The same thing I repeated basically in the whole project.

12. When I committed the code into git , api folders are missing. In the local repo also.

Thank you.
Highlighted
Occasional Contributor

Re: Renamed endpoints - ready api

There are some APIs I did not rename as similar to the test suite name. These APIs and test cases remain as it is.

View solution in original post

Highlighted
Community Hero

Re: Renamed endpoints - ready api

Hey @Manijem,

Before the commit/merge are you ensuring you are saving after the rename before you do the push? I know youd expect a save to occur as part of the push but id hit the save first just to be sure. I gotta admit, the fact that the renamed apis are disappearing makes me think youve found a defect, but we need to be sure.

As an exercise to determine exactly the boundaries of your issue, id try the following tests.

1. Rename apis, create tests against renamed APIs, HIT SAVE! then close down ReadyAPI! (without the commit/merge) and relaunch ReadyAPI! and check the state of the renamed apis.
Are the APIs still present?
Are the associated test cases still present?
Do the commit/merge
Pull the latest code back into ReadyAPI!.
Check the state of the renamed APIs/associated tests....are they both still present?

2. Create APIs, create tests, save, then commit/merge.
Pull the merged version back
Rename APIs, create a new test against renamed API, save, then commit/merge.
Pull the latest version back.
Check the state of the renamed APIs/associated tests....are they both still present?
Are the tests that were created against the API (before it was renamed) still present?

According to the detail youve provided, youre doing the renaming of the APIs via API Navigator rather than via the Projects tab. Can you follow my instructions above, but this time do the renaming of the APIs via the Projects tab rather than renaming via the API Navigator frame? (Dont forget to hit Save!).

I'm ezpecially interested in the tests associated with the API and whether they are present after youve pulled from git. The tests are child objects of the APIs, so you cant delete the API without delete the tests also, so if it is a defect it sounds like bit of a whopper.

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: Renamed endpoints - ready api

Thank you very much for your comprehensive answer. I will do as you said in future. Have a nice day !!!
New Here?
Join us and watch the welcome video:
Announcements
TechCorner Leaderboard
Want a fun and easy way to learn ReadyAPI and show off your skills? Try solving weekly TechCorner challenges and get into the Leaderboard!


Challenge Status

Compare an expected JSON value and actual response in Events

Participate!

Fetch value/data from JSON response using Groovy Script

See replies!

Filtering data retrieved from a DataSource

See replies!

Get data from Petstore and add it to Excel sheets

Participate!
Top Kudoed Authors