For LoadRunner 12.01 TruClient IE, how do we add Download filter so we only see our site and not the Facebook and LinkedIn sites?
Question ID: 105913
1
0
Marked as spam
Posted by (Questions: 231, Answers: 18)
Asked on January 31, 2015 1:47 pm
215 views
Answers (1)
1
Private answer

ANSWER:

Use the ''Utils.addAutoFilter'' function.

1. Add a ''Evaluate JavaScript'' step box to the top of the script
2. Add the following code,

Utils.cleanupAutoFilters();

Utils.addAutoFilter(''http://www.yoursite.com/*'', true);

Utils.addAutoFilter(''https://www.yoursite.com/*'', true);

.

Note: True = allow site false = block the sites. In this example, the code Is filtering out all sites except for the http & https://www.yoursite.com/*

In the TC-FF and in TruClient IE scripts , we used the following code to allow only ''yoursite.com'' sites thus blocking all other sites ( google-analytics.com, facebook.com, facebook.net, linkedin.com and *pi.pardot.com in my case)

Utils.cleanupAutoFilters();
Utils.addAutoFilter(''http://*yoursite.com/*'', true);
Utils.addAutoFilter(''https://*yoursite.com/*'', true);

--------------------------------------------------------------------------------------------------------

To block sites by ''name'' use this code with the ''false'' switch, and by commenting out different we can tell which external site(s) were adding biggest lag (in my case was the Facebook and LinkedIn)

Utils.addAutoFilter(''http://*analytics.com/*'', false);
Utils.addAutoFilter(''https://*analytics.com/*'', false);

Utils.addAutoFilter(''http://*facebook.com/*'', false);
Utils.addAutoFilter(''https://*facebook.com/*'', false);

Utils.addAutoFilter(''http://*facebook.net/*'', false);
Utils.addAutoFilter(''https://*facebook.net/*'', false);

Utils.addAutoFilter(''http://*linkedin.com/*'', false);
Utils.addAutoFilter(''https://*linkedin.com/*'', false);

* Be sure to add the semi-colon ; at the end of each line and the a return at the end of the last statement.

* Also verify that all LG are using the Same IE version as the VuGen machine did to create the script. (I.E. if VuGen used TruClient IE with IE 10 to create the script then ALL LGs need to be IE 10 )

Marked as spam
Posted by (Questions: 12, Answers: 384)
Answered on January 31, 2015 1:59 pm
EyeOnTesting

Welcome back to "EyeOnTesting" brought to you by Orasi Software, Inc.

X
Scroll to Top