Citrix Performance Monitoring

Tutorial 1: Test Case Building for Citrix Performance Monitoring

The goal of the test case is to monitor a Citrix login: Alyvix has to output the login performance, from your login form confirmation to the Citrix StoreFront.

The test has to run a browser at the Citrix access point, Alyvix has to detect, fill and confirm the login form and then Alyvix has to measure how long Citrix StoreFront takes to appear. Finally, the interaction flow has to log off that session and to shut down the browser.

1. Test case setup

a. create a new project (test case suite)
b. create a new test case
c. import the Alyvix basic keyword library (alyvixlib)

citrix_login_01_ride_setup

2. Run a browser

a. run Chrome (Create Process and the path of your browser executable; \ has to be written \\) pointing at the Citrix access point (URL and eventually browser options as –incognito for Chrome)
b. wait the browser opening (Wait Window and the regular expression of the browser window title)
c. maximize the browser (Maximize Window and the regular expression of the browser window title)

citrix_login_02_run_browser

3. Fill the Citrix login form

a. create an Alyvix custom keyword defining a Rect Finder made of three components: select the main as the username edit box, select the first sub component within its ROI as the password edit box and select the second sub component within its ROI as the confirm button (main SEL → sub 1 ROI → sub 1 SEL → sub 2 ROI → sub 2 SEL)

citrix_login_03_login_form

b. click CTRL  +   O  to open the dialog of keyword settings

c. set the main component detection and interaction options:

i. type the keyword name: citrix_login_form for example
ii. click on Use and Show Min/Max and then click on the four spin boxes below to adjust the valid area of the rectangle scrolling the mouse wheel
iii. click on Wait and then set the Timeout to, for example, 10 (seconds)
iv. click on Click, type arg1 in the edit box and then untick Add Quotes

citrix_login_03b_login_form

d. set the first sub component detection and interaction options:

i. click on sub_component_1 in the left pane
ii. click on Use and Show Min/Max and then click on the four spin boxes below to adjust the valid area of the rectangle scrolling the mouse wheel
iii. click on Click, type arg2 in the edit box and then untick Add Quotes

citrix_login_03c_login_form

e. set the second sub component detection and interaction options:

i. click on sub_component_2 in the left pane
ii. click on Use and Show Min/Max and then click on the four spin boxes below to adjust the valid area of the rectangle scrolling the mouse wheel
iii. click on Click

citrix_login_03d_login_form

iv. click on the Source Code tab and 2 Args (one for the main and one for the first sub)

citrix_login_03e_login_form

v. click on the Performance Data tab and untick Enable Performance, because we do not want to have the appearance performance of the Citrix login form

citrix_login_03f_login_form

f. look at the selection mask on the web application GUI in order to check the visual definition for each of the keyword components

citrix_login_03g_login_form

g. click on the OK button to confirm the Alyvix custom keyword: it is going to appear in the Alyvix keyword selector (keyword name and its type)

citrix_login_03h_login_form

h. import the Alyvix custom keyword library of the project (test case suite): it is a onetime operation, because you have created the first keyword for that project (and its Python module has been saved in the Alyvix robotproxy folder)

citrix_login_04_alyvix_proxy

i. type the brand new keyword in the test case (citrix_login_form or Citrix Login Form in its main table) with username (eventual \ has to be written \\) and password (we will see how to encrypt it)

citrix_login_05_add_citrix_login_keyword

4. Measure the appearance of the Citrix StoreFront page

a. create an Alyvix custom keyword defining an Image Finder made of three components: select the main as the Citrix StoreFront logotype, select the first sub component within its ROI as the Favorites icon and select the second sub component within its ROI as the user button (main SEL → sub 1 ROI → sub 1 SEL → sub 2 ROI → sub 2 SEL)

citrix_login_06_citrix_storefront

b. click CTRL  +  O to open the dialog of keyword settings

c. set the main component detection and interaction options:

i. type the keyword name: citrix_storefront_ready for example
ii. Threshold at 70% (as the default value) is fine in this case (we are mainly disambiguating the detection with several components)
iii. click on Move (just to see the mouse cursor moving after the detection)

citrix_login_06b_citrix_storefront

d. set the first sub component detection and interaction options:

i. click on sub_component_1 in the left pane
ii. click on Move (just to see the mouse cursor moving after the detection)

citrix_login_06c_citrix_storefront

e. set the second sub component detection and interaction options:

i. click on sub_component_2 in the left pane
ii. click on Don’t Click

citrix_login_06d_citrix_storefront

f. click on the Performance Data tab, leave Enable Performance ticked (by default) and set, for example, the Warning threshold at 10 (seconds) and the Critical one at 15 (remember we have set the Timeout at 20)

citrix_login_06e_citrix_storefront

g. click on the OK button to confirm the Alyvix custom keyword and type the new keyword name in the test case (citrix_storefront_ready or Citrix Storefront Ready in its main table)

citrix_login_06f_citrix_storefront

h. moreover add a table row at the top (click CTRL  +  I after having select one cell of the first row) to type the Alyvix basic keyword Add Perfdata and the name of the Alyvix custom keyword to monitor (citrix_storefront_ready in this case; do not type Citrix Storefront Ready)

5. Logout the session
Clicking on the account name (or its arrow icon) the account menu opens: there are three options, down and enter keystrokes allow selecting ‘Log off’. So that, the idea is to detect that element, to click on it and finally, to send keys to logout the session.

citrix_login_07_citrix_account_menu

a. create an Alyvix custom keyword defining an Image Finder made of one component: select the main as the little arrow icon that is right to the account name

citrix_login_07a_citrix_account_menu

b. click CTRL  +  O to open the dialog of keyword settings

c. set the main component detection and interaction options:

i. type the keyword name: citrix_account_logout_img for example
ii. click on Click
iii. type {down}{down}{enter} to send those keys after clicking

citrix_login_07b_citrix_account_menu

d. create an Alyvix custom keyword defining a Text Finder made of one component: select the main as the account name in its ROI (main ROI → main SEL)

citrix_login_07c_citrix_account_menu

e. click CTRL  +O to open the dialog of keyword settings

f. set the main component detection and interaction options:

i. type the keyword name: citrix_account_logout_txt for example
ii. type the regular expression about the text to detect in the selected ROI: muster for example (click on Check to verify is the OCR works fine)

citrix_login_07d_citrix_account_menu

g. create an Alyvix custom keyword defining an Object Finder made of two component: citrix_account_logout_img as the main and citrix_account_logout_txt as the sub

i. type the keyword name: citrix_account_logout for example
ii. click on Set Main Object, select citrix_account_logout_img from the Alyvix keyword selector list and click on Select
iii. click on Add Sub Object, select citrix_account_logout_txt from the Alyvix keyword selector list and click on Select

citrix_login_07g_citrix_account_menu

iv. select a ROI around the sub component to bind it with the main

citrix_login_07e_citrix_account_menu

citrix_login_07f_citrix_account_menu

v. click CTRL  +  O to open the dialog of keyword settings
vi. set the Timeout at 10 (seconds)
vii. click on the Performance Data tab and untick the Enable Performance box
viii. click on the OK button to confirm the keyword

6. Close the browser and report the outcome

a. type the new keyword name in the test case (citrix_account_logout or Citrix Account Logout)

b. type Close Window and, as its argument, the regular expression of the browser window title (citrix.*receiver for example)

c. type Print Perfdata to finally show performance measures on console and report

citrix_login_07h_citrix_account_menu

7. Run the test case and look at the outcome

a. click on the RIDE Play button (in the toolbar) or press F8 to run the test

b. leave the test case running until the end (or until it breaks)

c. click on the RIDE Log button (in the Run tab) to show the test report

citrix_login_08_report

Written by

The author didnt add any Information to his profile yet