###################### action ####################### -syncDatabase :restores the original : -syncCatalog : the oracle retrieves the catalog from the ps _database (might take some time) : -scan : scan the barcode given in the "barcode" param : -clearCart : empties the current cart : -defaultPage : makes the navigator go to the default page (Catalog tab>Catalog BrowseMode> Home) : ####################### config ######################## -randomPriceMax : configures the max random price that can be given to a free product -browseMode : configures the browseMode when looking ##################### unitTests ###################### ####### addToCart ####### possibles parameters : -None : simply add a random product to the cart. -idProduct (integer)/idProductAttribute (integer) : will browse the catalog and look for the given product. If no idProductAttribute is given then if the product has variations, we'll pick a random variation. -category (integer)/ position(integer) will go to the given category and position and pick the article. The method will fail if no item corresponds to the given parameters. is found. if category <0, a random category will be chosen (the first non empty one), if position <0, a random position will be chosen. -type (free/withVariations/std) : will look for all the products of the given variety and pick a random one among these (needs to be called after syncCatalog) Available options : browseMode : "quick" or "catalog" ** Possible ways to add an item to the cart : ** 1°) with categoryIndex and productIndex will go to the given category and product position and pick the article. The method will fail if no item corresponds to the given parameters. if categoryIndex <0 or is not provided, a random category will be chosen (which might be empty. In this case, no item will be added), CategoryIndex might be 0 (the programm will browse the catalog's homePage on which there are both categories and product if productIndex <0 or is undefined , a random one will be chosen. eg : will select the 3rd item in the 3rd category in the "quick" view. will select a random item in the 3rd category in the "catalog" view will select the 3rd item in a random category -------> might fail will select a random article in a random category. If the category is empty. No item will be added and the test wont fail 2°)Using product id : will pick an item with the idProduct 13 and idProductAttribute 1600 (if it exist and fail otherwise) will pick an item with the idProduct 134 and if it is a free price product, it will give it the price 51 Will pick a random STD article in the catalog (hence the synCatalog) and add it to the cart (3 times in a row) Will pick a random Free price product in the catalog and add it to the cart (with a random price). A catalog synchronization must be performed before this test. Will pick a random variation of a random product with variations // Browse with categoryIndex and productIndex. //Examples checkCart : compares the html Cart, with the expected one (described in xml) possibles parameters : useId (default true) : Set to true to take into account the id (id_product_attribute,id_product, reduc_id) during the comparison usePosition (default false) Set to true to take into account the position of the items during the comparison expected description : cart : a list of cartItem and reduc * cartItem : can be described with the attributes : -idProduct: default is a negative integer (unique in the cart) -idProductAttribute : default is 0 -pos: default is 0 -cumulativePrice : mandatory -n : number of times the item has been added to the cart. Mandatory * reduc : can be described with the attributes : -id: default is a negative integer (unique in the cart) -pos: position in cart relative to the others reduc, default is 0 -amount : a negative float (mandatory) //Example : ##################### causes possibles d'échecs de tests ###################### erreurs d'arrondi (côté java). L'interface html a changé.