Home

Magento Test Automation Framework User's Guide

image

Contents

1. store_name j Steps Sthis gt clickButton create_store Sthis gt fillForm S storeData Sthis gt saveForm save_store Verifying Sthis gt assertTrue Sthis gt successMessage success_saved_store Sthis gt messages Sthis gt assertTrue S this gt checkCurrentPage manage_stores After successful creation store should be redirected to Manage Stores page Creating a Test Suite The next step is creating a test suite In this example we ll be using test cases which were created for Auto Testing Scenario 1 Verifying the Catalog Advanced Search page with valid data Open the Main Page Frontend Navigate to the Catalog Advanced Search page Complete all fields with valid data Select Tax Class None Click the Search button CPN Expected result The product should be displayed on the Advanced Search Results page Scenario 2 Verifying the Catalog Advanced Search error message with empty fields 1 Open the Main Page Frontend 2 Navigate to the Catalog Advanced Search page 3 Leave all fields empty 4 Click the Search button Expected result The error message Please specify at least one search term should be displayed
2. c oO Oo Oo FANN WK NNN NNN AANA A A K O D k 1 k k k k k k k O O 0 0 20 EE E E EE Oo MOANA LH S LJ K LA oS 5 234567890 6 AdminUser_Crea invalid_password 7 8 231234qwe AdminUser_CreateTest 9 20 21 22 23 24 25 qwertyqw TAP version 13 AdminUser_Delete AdminUser_Delete AdminUser_Create AdminUser_Create AdminUser_Create AdminUser_Create AdminUser_Create AdminUser_Create AdminUser_Create AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea invalid_password AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea AdminUser_Crea Test Test Test Test Test Test Test Test Test Test Test Test te tel tel Test teTest teTest ce invalid_password teTest teTest teTest password_unmatch ce Test Test Test Test Test AdminUser_LoginTest loginValidUser Example of Results Display in TAP File Format test_DeleteAdminUser_Deletable test_DeleteAdminUser_Current test_Navigation test_WithRequiredFieldsOnly test_WithUserNameThatAlreadyExists test_WithUserEmailThatAlreadyExists test_WithRequiredFieldsEmpty with data set 0 user_name 1 test_WithRequiredFieldsEmpty with data set 1 first_name 1 test_WithRequiredFieldsEmpty with data set 2 last_name 1 itest
3. etc Several of them are provided in the examples below Example of Text Execution Progress Display in Text File Format P E O a REI PE ET 63 527 11 j F aiar BG a E EES Eea Ea AAE ran E N A A AEN 126 527 23 i Mi aa RRR wud E E TE dea SRG a RT al aces debe Ea ema aE SS Reece 189 527 35 i R R O Arata EELEE TE SSSS std do saia taena 252 527 47 i I a EERE netics at des aT seis eta lg E E RT arah eE 315 527 59 f TE N A EA eee keene oo ee dese ee E ees 378 527 71 f Daga T E E E T 441 527 83 j l E EE E EE FFF F SSS aoan re i E E E 504 527 95 j Example of Results Display in JSON File Format event suiteStart suite All Tests tests 527 a event suiteStart suite AdminUser_DeleteTest tests 2 pa event testStart suite AdminUser_DeleteTest test AdminUser_DeleteTest test_DeleteAdminUser_Deletable 1 2 event test suite AdminUser_DeleteTest test AdminUser_DeleteTest test_DeleteAdminUser_Deletable status pass time 45 594885826111 trace message Yn Pod event testStart suite AdminUser_DeleteTest test AdminUser_DeleteTest test_DeleteAdminUser_Current E event test suite AdminUser_DeleteTest test AdminUser_DeleteTest test_DeleteAdminUser_Current status pass time 17 709816932678 trace message pt K O O O OO O 0 0 R
4. lt li gt lt li gt test WithLongValues lt li gt lt li gt test WithInvalidPassword lt li gt lt li gt test WithInvalidEmail lt li gt lt li gt test InactiveUser lt li gt lt li gt test WithRole lt li gt lt li gt test WithoutRole lt li gt lt ul gt Example of Results Display in Testdox Text AdminUser_Delete x test DeleteAdminUser Deletable x test DeleteAdminUser Current AdminUser_Create x test Navigation x test WithRequiredFieldsOnly x test WithUserNameThatAlreadyExists x test WithUserEmailThatAlreadyExists x test WithRequiredFieldsEmpty x test WithSpecialCharacters exeptEmail x test WithLongValues x test WithInvalidPassword x test WithInvalidEmail x test InactiveUser x test WithRole x test WithoutRole AdminUser_Login Login valid user Login empty one field Login non existant user Login incorrect password Login inactive admin account Login without permissions Forgot empty password Forgot password invalid email Forgot password correct email Forgot password old password x x KM NR NR KM KM KM MK Example of XML File Format lt testsuites gt lt testsuite name All Tests tests 194 assertions 713 failures 0 errors 0 time 2974 288380 gt lt testsuite name AdminUser_CreateTest file D Work selenium saas tests AdminUser CreateTest php fullPackage selenium tests package selenium subpackage tests tests 22 asser
5. of all types Such operations are highly flexible providing many options for locating Ul elements and comparing expected test results against actual application behavior One of Selenium s key features is support for executing tests on multiple browser platforms Selenium uses a simple but powerful Document Object Model DOM which also allows tests to be exported to multiple programming languages and frameworks The Selenium framework includes the following tools S Selenium Integrated Development Environment IDE is a prototyping tool for building test scripts a Firefox plugin that provides an easy to use interface for developing automated tests Selenium IDE has a recording feature which records user actions as they are performed then exports them as a reusable script that can be later executed in one of many programming languages It contains a context menu that allows you to first select a UI element from the browser s currently displayed page and then select from a list of Selenium commands the commands have pre defined parameters according to the context of the selected UI element One can record and playback automated tests without needing to know a test scripting language This is not only a time saver but also an excellent way of learning Selenium script syntax e Selenium Remote Control RC is a test tool that allows you to write automated web application UI tests in any programming language against any HTTP website using any mainstr
6. F is a system of software tools used for running repeatable functional tests Test against a normally installed Magento application Automation Framework MTAF is used for both writing test automation scripts and for performing the actual testing Test automation scripts created within MTAF the framework can be used for testing most Magento functionality which does not relate to an external system This is a cross platform solution not dependent on a specific operating system MTAF allows QA specialists to quickly develop all kinds of tests for the current Magento version and the tests can be reused at any time Framework users can run a single test independently a bunch of tests together a test suite or all available tests Test A Test Automation Script is a PHP class dependent on the PHPUnit framework and the Selenium library The script initiates the Automation running of a specific test case or a suite of test cases Script DataSet A DataSet is a data file or set of data files required for running automated tests Such file s are created in the YAML format For more information refer to the MTAF Logical Structure section UI Map A UI Map is used to define store and serve the UI elements of an application or website In the case of Magento website the definition of Ul elements depends on the Selenium technology which uses strings and XPATH to locate and define UI elements In other words a UI Map is a repository of test script ob
7. Magento Test Automation Framework User s Guide The Magento Test Automation Framework MTAF is a system of software tools used for running repeatable functional tests against the Magento application being tested This framework can be used for automating most routine processes in Magento such as e Registering or creating customers in the frontend and in the Admin Panel e Adding addresses to customer accounts e Creating websites web stores and store views MTAF is used for both writing test automation scripts and for performing the actual testing Test automation scripts created within the framework can be used for testing most Magento functionality which does not relate to an external system This is a cross platform solution not dependent on a specific operating system MTAF allows QA specialists to quickly develop all kinds of tests for the current Magento version and the tests can be reused at any time Framework users can run a single test independently a group of tests together a test suite or all available tests from a single command This guide provides instructions on using the test automation framework It explains the environment requirements for the MTAF and describes the process of running tests and reviewing the results This document is intended for specialists who are either interested or involved in using the Magento Test Automation Framework hereinafter referred to as MTAF This framework is used to run automated tests agai
8. _WithRequiredFieldsEmpty with data set 3 email 1 itest_WithRequiredFieldsEmpty with data set 4 password 2 itest_WithRequiredFieldsEmpty with data set 5 password_confirmation test_WithSpecialCharacters_exeptEmail itest_WithLongValues itest_WithInvalidPassword with data set 0 array 1234567890 i test_WithInvalidPassword with data set 1 array qwertyqw test_WithInvalidPassword with data set 2 array l23qwe 123qwe itest_WithInvalidPassword with data set 3 array 123123qwe test_WithInvalidEmail with data set 0 invalid test_WithInvalidEmail with data set 1 test invalidDomain test_WithInvalidEmail with data set 2 te st magento com test_InactiveUser test_WithRole test_WithoutRole Example of Results Display in HTML File Format lt html gt lt body gt lt h2 id AdminUser_DeleteTest gt AdminUser_Delete lt h2 gt lt ul gt lt li gt test DeleteAdminUser Deletable lt li gt lt li gt test DeleteAdminUser Current lt li gt lt ul gt lt h2 id AdminUser_CreateTest gt AdminUser_Create lt h2 gt lt ul gt lt li gt test Navigation lt li gt lt li gt test WithRequiredFieldsOnly lt li gt lt li gt test WithUserNameThatAlreadyExists lt li gt lt li gt test WithUserEmailThatAlreadyExists lt li gt lt li gt test WithRequiredFieldsEmpty lt li gt lt li gt test WithSpecialCharacters exeptEmail
9. a v 0 gt dl 59 uy 55 R THT T e lt e n e O a o i a pp o U A py D 0 O IB p aG 0 a p n 2 0 Q B __success_deleted_message Xpath __error_message Xpath Custom UIMap Example e Create a new yml file under magento afw x x x uimaps either by using the UIMap template or by creating a custom one using the example Example of Custom UIMap Manage Stores page manage_stores mca system_store title Stores System Magento Admin uimap form fieldsets manage_stores xpath div id storeGrid buttons reset_filter button span Reset Filter search button span Search links select_store_view td normalize space class a left last a text SNAME S fields website_name input id filter_website_title store_name input id filter_group_title buttons create_website button span Create Website create_store button span Create Store create_store_view button span Create Store View messages success_saved_store li normalize space class success msg span text The store has been saved success_saved_store_view li normalize space class success msg span text The store view has been saved success_saved_website li normalize space class success msg span text The website has been saved success_deleted_store li normalize space class success msg span text The store has been deleted success_
10. deleted_store_view li normalize space class success msg span text The store view has been deleted success_deleted_website li normalize space class success msg span text The website has store_view_name input id filter_store_title i been deleted i d Creating a Custom DataSet A Custom DataSet is a file which contains sets of data for form filling e Each set corresponds to a variation of form filling responses e Each set contains the following pairs forms_field_name value Custom DataSet Example Create a new yml file under magento afw x x x data with the following structure Example of Custom DataSet Structure generic_store_view list of fields with test data value store_name Main Website Store store_view_name Test Store View Name store_view_code test_store_view_code store_view_status Enabled all_fields_store_view store_name Main Website Store store_view_name Test Store View Name 2 store_view_code test_store_view_code_2 store_view_status Enabled store_view_sort_order 1 Creating a Custom TestScript Creating a custom test script is easy 1 Know what you want to test 2 Create a trivial TestCase 3 Create a TestScript based on the TestCase and on the sample of code below Custom TestScript Example e Write a new TestScript by creating CreateTest test php with the following structure i Example of Test Script Structure class Something_Create_Test e
11. der contains two major files config yml and local yml The config yml file is used as a template for configuring the Selenium client For more information on using these files refer to the MTAF Configuration section e The library folder contains the entire class hierarchy from the API framework The uimaps folder stores YAML files with descriptions of UlMaps for tests It contains all UlMaps used in tests and may include some custom ones e The data folder contains all of the input parameters for all tests Test data can be loaded to this folder with the help of the loadData method as follows SstoreData this gt loadData generic_store Null store_name The tests folder contains PHP files with test suite classes NA PHP Unit Selenium Starting MTAF 1 Run Selenium Server 2 Execute runtests bat in Windows through the command prompt for tests running 3 Executing runtests sh for Linux NIX OS is not implemented yet Running Tests When choosing the appropriate method for running tests you must consider the quanitity of tests whether it is a single test a test suite or all tests test sites local remote distributed machines or cluster and continuous integration practices You also need to take into account testing purposes when choosing a way to run your tests such as test script debugging manual start or continuous integration Based on these factors you may choose to run your tests from the In
12. eam JavaScript enabled browser e Selenium Web Driver is a tool for writing automated tests for websites It aims to mimic the behavior of a real user and as such interacts with the HTML of the application e Selenium Grid is a Selenium derivative that allows developers and QA personnel to access Selenium Remote Controls without worrying about where the Selenium Remote Controls are located As a developer or QA specialist one can create a script as one would for Selenium Remote Control and run it as usual MTAF Environment Requirements Before you start using the Magento Test Automation Framework make sure that you have the following software installed PHP 5 2 0 or later PHPUnit 3 5 13 or later Java Run time Environment JRE 1 6 or later An Integration Development Environment it is recommended to use NetBeans 6 9 1 or later alternatively it is possible to use other frameworks such as Zend Eclipse etc Selenium Remote Control RC 1 0 3 or later 2 0 rc2 TortoiseGIT recommended but optional Magento Community Edition 1 5 or later For details about installing and configuring the necessary applications refer to the Magento Test Automation Framework Installation Guide Note In addition make sure that the following requirements are met The Selenium RC server must be able to locate the browser s EXE file in order to successfully run a browser For more information about this refer to the official Selenium documentatio
13. jects which correspond to UI elements of the application being tested User When this document refers to the User it refers to a Quality Assurance Engineer PHP Developer or other person with similar skills and responsibilities working with the MTAF Document The Document Object Model DOM is a cross platform language independent convention for representing and interacting with Object objects in HTML XHTML and XML documents Aspects of the DOM such as its Elements may be addressed and manipulated Model within the syntax of the programming language in use The public interface of a DOM is specified in its application programming DOM interface API Scope This section presents a brief overview of each chapter s contents e Introduction to Magento Automated testing describes the benefits and workflow of automated testing It also provides the list of tools and frameworks used to maintain automated testing e MTAF Environment Requirements lists the software required to use MTAF and the list of Web browsers supported by Magento and thus MTAF MTAF File Formats describes the file formats used for MTAF files MTAF Logical Structure provides a graphical representation of MTAF logic MTAF File Structure provides an overview of files used for the MTAF their location and content Starting MTAF provides instructions for starting MTAF Running Tests describes the process of running tests Results of Running Tests provides examples of te
14. k from the command prompt you need to have a BAT file with the phpunit xml configuration The same logic is used for running tests from a continuous integration server which we will discuss later You can configure your phpunit xml file to run all tests a specific test suite or just a single test Example of All Tests Configuration ee esd lt testsuite name All Tests gt lt directory suffix php gt tests lt directory gt L lt testsuite gt Example of Test Suite Configuration d lt testsuite name Test Suite gt lt directory suffix Test php gt tests Customer lt directory gt lt testsuite gt i lt directory suffix Test php gt tests Store lt directory gt L Example of Single Test Configuration weeeed lt testsuite name Single Test gt lt directory suffix test_file _full_name gt file_path_from_test_category lt directory gt lt testsuite gt Running tests this way requires far fewer machine resources and the tests are executed more quickly but it does not provide you with full debugging capabilities Continuous Integration Server Running tests from a continuous integration server is based on the same logic as running tests from the command prompt Tests are run automatically on the server using a preconfigured phpunit xml file The Magento installation on the server is continuously updated and then it runs all the specified tests according to the defined schedule Unlike runni
15. model includes every single Ul element that can exist on a page Xpath locators are paths to such UI element in a DOM model Thus using Xpath expressions it is possible to link any Ul element on a page even a hidden one with a method that imitates an action being executed upon it a method in the MTAF library For example one can use UIMaps Xpath expressions and a click method from the MTAF library to reproduce clicking any UI element on the specified web page An example of using such an approach can be the re testing of the localized application A DataSet is a pool of YAML files data storage which describe the data main space being referred to by the test case files For search convenience purposes the data main space is logically split into several data files Each data file can be related to a specific functionality being tested and thus related to specific test case files A Test is generally speaking a single action or sequence of actions that evaluates whether a specific feature meets functional requirements It can be said that a test is a method in a class which is inherited from the basic test case class The test calls a library function or functions which in turn executes the actions required to check the application s expected business logic MTAF File Structure As you can see from the diagram at the right all MTAF files are located in five main directories config library uimaps data and tests e The config fol
16. n A custom browser profile must be created to be used by Selenium for running automated tests For more information about this refer to the Magento Test Automation Framework Installation Guide MTAF Supported Web Browsers Mozilla Firefox 3 x or later Google Chrome Internet Explorer 6 0 and later Safari 5 or later MTAF File Formats There are three file formats used for MTAF files e XML The only meaningful XML file used in MTAF is the phpunit xmlI configuration file e PHP In MTAF PHP files are basically used in two situations e Test case files located in the tests directory test cases can be run based on the configuration defined in the phpunit xmI file and use the input data set specified in the DataSet YAML files e Framework library files S YAML Most MTAF files are created in the YAML format a human readable data serialization format these can present either UlMap files or data set files MTAF Logical Structure The following illustration explains the basics of MTAF logic What is What is input concept data _ What are sequence of actions A UlMap is a concept for defining storing and serving UI elements of an application or a website The UlMap file YAML file contains a set of key value pairs where each key is the alias of a Ul element and the corresponding value is an Xpath locator In terms of the UlMap each page rendered by a browser is presented as a Document Object Model DOM Such a
17. ng tests from a command prompt this method of running tests is totally automated Results of Running Tests You may view results of running tests with the help of standard command prompt output If you need more precise error localization you may want to use additional PHPUnit logging tools Logs are stored in a separate tmp folder and you can always access them for analysis Command Prompt After executing runtests bat from the command prompt you can see the current progress of running your tests It provides an overview without detailed information i Example of Test Results Display in Text File Format tier HRA Ka E ee bene BR RENA NR RRR AR TRR wa eed 63 228 27 RAE cine Get EEE ATA a anaes 126 228 55 L aE S EEE E E EOE EA E Deea e a tans a E A AE A E A deo 196 228 75 oe Be Ger etchant T eens ni aan hea Oa By shia tate bred A dar A 228 228 100 Tests 228 Assertions 396 Failures 2 Errors 2 Incomplete 2 Skipped 1 e test PASSed e S test SKIPped e test INCOMPLETE e F test FAlLed S E ERROR occurred during test More details about PHPUnit results generation are available on the PHPUnit website Logs PHPUnit logging tools provide more detailed information about test results Once you execute runtests bat log files containing detailed information about test execution are created in the same directory Log files are created in several different formats plain text XML HTML
18. nst a normally installed Magento application Primarily this document is aimed at Magento Quality Assurance specialists and PHP developers Note Using the Magento Test Automation Framework requires advanced knowledge of XML YAML and PHP for installing the necessary working environment creating functional tests executing the tests created and using test results properly e About this Document e Conventions S Glossary e Scope e Introduction to Magento Automated Testing MTAF Environment Requirements e MTAF Supported Web Browsers MTAF File Formats MTAF Logical Structure MTAF File Structure Starting MTAF Running Tests Integrated Development Environment IDE S Command Prompt e Continuous Integration Server e Results of Running Tests e Command Prompt Logs e MTAF Instructions e Creating a Custom UIMap e Creating a Custom DataSet e Creating a Custom TestScript e Creating a Test Suite Related Documents S Magento Test Automation Framework Installation Guide About this Document This section is intended to clarify the structure content and presentation of information in this document Conventions The following text formatting conventions are used to accentuate specific types of information e Bold is used to highlight paths to files Bold Italics is used to highlight file names e Code Style is used to highlight samples of code Glossary Term Description Magento The Magento Test Automation Framework MTA
19. sed to diagnose whether the application s functionality meets defined functional requirements Using the AFT approach confirms that the code for each specific function or feature accomplishes the corresponding tasks successfully Secondly running functional tests confirms that the application operates exactly as expected The workflow for using AFT in Magento applications can be presented as follows Qn E GM Identify tasks that the application or feature must accomplish Create necessary input data Define expected results to be used as a benchmark for application or feature functionality QA specialist executes a test QA specialist compares expected results with actual results and determines whether the test has been passed successfully Magento Test Automation Framework MTAF uses the following tools and frameworks PHPUnit is a unit testing framework for the PHP programming language Its purpose is to find mistakes in PHP source code The major benefit of using PHPUnit is the ability to establish a testing infrastructure and to re use it as often as needed simply by creating unique parts for each particular test Selenium is a well know open source testing framework widely used for testing Web based applications It contains a variety of software tools each with a different approach to support test automation These tools provide a rich set of testing functions specifically geared to the needs of web application testing
20. st results MTAF Instructions provides instructions on custom UIMap DataSet test script and test suite creation Introduction to Magento Automated Testing Testing also known as Quality Assurance or QA is an essential part of the software development process While testing intermediate versions of products being developed the Magento quality assurance team QA team needs to execute a number of tests In addition prior to publishing each new version of the Magento platform it is mandatory that the version pass through a set of regression and smoke tests These tests are standard for every new version of Magento products and therefore can be automated to save human resources and time required for executing them The benefits of using automated testing are e Simplified testing procedures which use existing automated tests e Reduced test execution time and human resource requirements e Complete control over the tests results actual results vs expected results e Freedom to quickly change a test s preconditions and input data and re run tests dynamically Currently there are two major approaches used for automated testing Unit Testing hereinafter UT and Automated Functional Testing hereinafter AFT In Magento the UT approaches is rarely used because it requires significant time and resources to establish dependencies between different modules AFT for Magento means an automated process u
21. tegrated Development Environment IDE from the command prompt or from the continuous integration server Integrated Development Environment IDE The Integrated Development Environment IDE provides you with a great variety of tools and plugins which help you write debug and run your tests The IDE is recommended for running all tests or specific test suites rather than single tests It is the simplest and most precise way of working with tests you may easily write a test script and debug it in the IDE however the IDE does not provide you with full control over the tests or continuous integration The following instructions are specific to the NetBeans IDE If you are using a different IDE refer to that product s documentation for instructions Before running tests you must add MTAF to the IDE Running All Tests 1 Select the project node in the file tree Projects window 2 Right click this node then select Test or press Alt F6 Running Individual Tests 1 Select the test file the file node you want to run 2 Right click the file in the file tree Projects window then click Run or Press Shift F6 to run the test opened in the edit window Command Prompt The command prompt provides you with full control over your tests and independence from platforms It also enables you to start your tests manually This option is most preferable when you have already debugged the tests and they can be run in production To wor
22. that will be run f E E HHT E Creating a Custom UIMap Custom UIMap Template S In general the UIMap template looks like the following i Example of UIMap Template _page_name __mca URL without BaseURL title page title __uimap __form amp formLink __tabs __tab_name_1 xpath tabXpath ee I lk i fieldsets __fieldset_name_1 xpath fieldsetXpath buttons fieldset_button_name_1 buttonXpath __fieldset_button_name_2 buttonXpath __fieldset_button_name_3 buttonXpath __checkboxes __checkbox_name_1l checkboxXpath __checkbox_name_2 checkboxXpath dropdowns __dropdown_name_1l dropdownXpath __dropdown_name_2 dropdownXpath links __link_name_1 linkXpath __link_name_2 linkXpath __multiselects __multiselect_field_name_1l Xpath __multiselect_field_name_2 Xpath fields __field_name_1 fieldXpath __field_name_2 fieldXpath __radiobuttons __radiobutton_name_1l radiobuttonXpath __radiobutton_name_2 radiobuttonXpath __ required required_field_namel required_field_name2 __fieldset_name_2 __xpath fieldsetXpath __fieldset_name_3 __xpath fieldsetXpath fieldsetXpath S oO GG oO G pp D g o 0 x D p S Q D v p xo x om Q a oO aa oO x ko Q 0 0 D 9 S A Bb 7 8 8 a fd 53 2 gt A Mt e Se E E a Q g da E 8 S R N 3 9 5 7 g D K
23. tions 68 failures 0 errors 0 time 491 137801 gt lt testcase name test_Navigation class AdminUser_CreateTest file D Work selenium saas tests AdminUser CreateTest php line 71 assertions 6 time 26 675233 gt SN a te lt testsuite gt v Noster ar et ated lt testsuites gt MTAF Instructions After unpacking the downloaded project the user will see the following structure for the Magento TAF Example of MTAF Structure __ magento afw x x x j l __ config Contains files with Selenium Server configuration H config yml Contains the list of browsers for testing j l yml f __ data Contains test Data Sets for running test cases f l DataSetFile yml Contains files with test data yml f l Alib Contains Magento Test Automation Framework sources i l __ Mage H t __ Selenium LibraryFile php php __ tests Contains the files with test scripts divided by specific functional areas i __ FunctionalityGroupNamel example Customer FGN1TestScript php example Register php __ FunctionalityGroupName t __ uimaps Contains page elements UIMaps for all pages that need to be tested 1 __ admin l FunctionalityRelatesUIMAPFile yml for example dashboard yml i ym l i __ front H H FunctionalityRelatesUIMAPFile yml H l yml l H _ paypal_ui l i FunctionalityRelatesUIMAPFile yml H i yml f l __phpunit xml Contains the list of test cases
24. xtends Mage_Selenium_TestCase protected function assertPreConditions Preconditions Sthis gt loginAdminUser Log in Sthis gt assertTrue S this gt checkCurrentPage dashboard Wrong page is opened Sthis gt navigate manage_stores j Navigate to System gt Manage Stores Sthis gt assertTrue Sthis gt checkCurrentPage manage_stores Wrong page is opened public function test_Navigation Test case which verify presence of a controls on the page Sthis gt assertTrue this gt clickButton create_store_view There is no Create Store View button on the page action clickButton Sthis gt assertTrue S this gt checkCurrentPage new_store_view Wrong page is opened Sthis gt assertTrue Sthis gt controlIsPresent button back There is no Back button on the page Sthis gt assertTrue this gt controlIsPresent button save_store_view There is no Save button on the page Sthis gt assertTrue this gt controllIsPresent button reset There is no Reset button on the page Create Store Fill in only required fields Steps 1 Click Create Store button 2 Fill in required fields 3 Click Save Store button Expected result Store is created Success Message is displayed public function test_WithRequiredFieldsOnly Data SstoreData S this gt loadData generic_store Null

Download Pdf Manuals

image

Related Search

Related Contents

Nostalgia Electrics KRS-6100SS Use and Care Manual  HIOKI 3283 Pince Ampèremétrique pour courant de fuite  設備チェックリスト(安全面)  Manual - Hearth & Home Technologies  eZ80F91 Development Kit User Manual  ダウンロードはこちら  Philips DesignLine Edge Smart LED TV 42PDL7906T  Metroplan Write-on  Dakota Digital UTV-1000 User's Manual  User Guide  

Copyright © All rights reserved.
Failed to retrieve file