This is a migrated thread and some comments may be shown as answers.

Base URL - Multiple Sites, Multiple Environments

4 Answers 261 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bob
Top achievements
Rank 1
Bob asked on 22 Apr 2013, 02:32 PM
Hey there,

Let's say I have two sites...

http://shopping.mycompany.com/ - Shopping Site
http://admin.mycompany.com/ - Administers Shopping Site

And I have many environments...

http://devshopping.mycompany.com - Developer
http://uatshopping.mycompany.com - UAT
http://shopping.mycompany.com - Released

I want to schedule a test list on a remote machine for the DEV environment to run every night.
I want to schedule the same test list on the local machine for the RELEASE environment to run every night.

Obviously, I want to avoid copy pasting each test for each environment. I created a step to extract text from an input box (either dev, uat, or nothing) and run coded navigation steps. Thus, I must change a test step in this "Environment" test each time I want to run my tests in a different environment. The issue is that I can not simultaneously run my tests at night in multiple environments.

This sounds like a great job for the Base URL option. I'll create a test list for each build and set a different base URL each time. However, i'm experiencing an issue with Base URL.

The base URL for my dev test list is "http://dev" for example. I expect this to then append to "~shopping.mycompany.com" to create... "http://devshopping.mycompany.com". Instead, it attempts to navigate to "http://dev/shopping.mycompany.com", adding a slash.

Is there a way to get rid of that slash?

4 Answers, 1 is accepted

Sort by
0
Rodney
Telerik team
answered on 23 Apr 2013, 03:06 PM
Hi Robert,

Thank you for contacting Telerik. If I understand your problem correctly, you would like to set the BaseURL for multiple environments but are having an issue with the configuration.

I think you are on the right path and simply need to make a minor change. You should enter the entire domain name into the BaseURL field. So rather than entering ‘http://dev’ , you should enter ‘http://devshopping.mycompany.com’ as your BaseURL.

Then you can configure your Test Lists to run in multiple environments using the entire domain name like http://uatshopping.mycompany.com and http://shopping.mycompany.com as the BaseURL.

You cannot prevent the BaseURL feature from adding the slash but if you use the entire domain name, you shouldn't need to. 


Regards,
Rodney
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
0
Bob
Top achievements
Rank 1
answered on 23 Apr 2013, 03:25 PM
Rodney,

As I explained in the original post, each environment has two sub domains

http://shopping.mycompany.com/ - Shopping Site
http://admin.mycompany.com/ - Admin for the above shopping site

Thus, when I'm working in the "UAT" environment, I need to navigate to...

http://uatshopping.mycompany.com/
http://uatadmin.mycompany.com

So my URL parses like this...

1) Protocol: http://
2) Environment: dev, uat or blank
3) Sub Domain: admin, shopping
4) Domain: mycompany.com

Right now, I have a very round about way of navigating to different environments. I navigate to a site, put the environment into an input field, extract that data, and use that variable in every navigation (coded step), but this is only used in two tests - navigating to the shopping site or navigating to the admin site. This prevents me from running the tests in two environments overnight. It also means that if I forget to change the test over to the other environment before I leave, our regression testing fails.

-Robert
0
Bob
Top achievements
Rank 1
answered on 23 Apr 2013, 03:55 PM
I should also add that reporting is a bit trickier. If I was able to set a base URL and copy test lists for each environment, my reporting would say "Dev - Test 1" instead of just "Test 1".

0
Rodney
Telerik team
answered on 26 Apr 2013, 08:14 PM
Hi Robert,

Thank you for the clarification. Our BaseURL feature automatically appends a slash after the URL value into the project's BaseURL. I understand the importance of getting this feature to work in your environment but the behavior cannot be changed to prevent a slash from being added.

I've created a feature request for the functionality that you are requesting. You can vote for the feature and view the details at this address: Public URL.

Regards,
Rodney
the Telerik team
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
Tags
General Discussions
Asked by
Bob
Top achievements
Rank 1
Answers by
Rodney
Telerik team
Bob
Top achievements
Rank 1
Share this question
or