From d2b8b015770f755ae77fa19fc93aa8eba164c62a Mon Sep 17 00:00:00 2001 From: Jean-Christophe Engel Date: Fri, 13 Sep 2024 10:49:39 +0200 Subject: [PATCH] ajout 12-04 email non obligatoire --- membres.side | 395 ++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 394 insertions(+), 1 deletion(-) diff --git a/membres.side b/membres.side index 323fd2a..ed53723 100644 --- a/membres.side +++ b/membres.side @@ -43713,6 +43713,399 @@ ], "value": "" }] + }, { + "id": "2c1df50d-b2c8-4f68-92d5-8aaa5a45b4de", + "name": "12-04 email obligatoire", + "commands": [{ + "id": "a0a54661-2b03-434e-b065-00bcc92cf1c8", + "comment": "", + "command": "open", + "target": "http://test.paheko.localhost/admin/login.php", + "targets": [], + "value": "" + }, { + "id": "86fa8340-2f0f-4852-8da2-3195e034a9ff", + "comment": "", + "command": "setWindowSize", + "target": "1280x1020", + "targets": [], + "value": "" + }, { + "id": "78c40f79-3bbb-4d98-b5c0-827e11ced20d", + "comment": "Vérifier si déjà connecté", + "command": "storeXpathCount", + "target": "xpath=//button[@name='login']", + "targets": [], + "value": "connecte" + }, { + "id": "fb9707a1-308f-4657-bc23-161c06ce18de", + "comment": "", + "command": "if", + "target": "${connecte} > 0", + "targets": [], + "value": "" + }, { + "id": "18dbc499-80a1-4910-b46d-f698acd6976b", + "comment": "identifiant", + "command": "type", + "target": "id=f_id", + "targets": [], + "value": "jckix@free.fr" + }, { + "id": "6e02b8de-2d50-43ac-85ea-5e6ef4898bc1", + "comment": "mot de passe", + "command": "type", + "target": "id=f_password", + "targets": [], + "value": "interpeller noircir colis allumer" + }, { + "id": "e54dc6a5-8b24-49af-93bc-184f98693c71", + "comment": "Connexion", + "command": "click", + "target": "name=login", + "targets": [], + "value": "" + }, { + "id": "98876705-66d5-4cfc-8d1e-0ef3681eee31", + "comment": "", + "command": "end", + "target": "", + "targets": [], + "value": "" + }, { + "id": "953f0ec4-f65a-4cc1-8fc5-3193758fcdf8", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/\")]", + "targets": [ + ["css=li:nth-child(6) b", "css:finder"], + ["xpath=//li[6]/h3/a/b", "xpath:position"], + ["xpath=//b[contains(.,'Configuration')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "44e5d289-fa98-4c5d-b0c9-cf6e3e46e3f2", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/users\")]", + "targets": [ + ["css=ul:nth-child(1) > li:nth-child(3) > a", "css:finder"], + ["xpath=//a[contains(text(),'Membres')]", "xpath:link"], + ["xpath=//a[@href='http://test.paheko.localhost/admin/config/users/']", "xpath:href"], + ["xpath=//nav/ul/li[3]/a", "xpath:position"] + ], + "value": "" + }, { + "id": "78d48a6a-0108-42c3-820b-4a186bce19a1", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/fields\")]", + "targets": [ + ["css=ul:nth-child(1) > li:nth-child(3) > a", "css:finder"], + ["xpath=//a[contains(text(),'Membres')]", "xpath:link"], + ["xpath=//a[@href='http://test.paheko.localhost/admin/config/users/']", "xpath:href"], + ["xpath=//nav/ul/li[3]/a", "xpath:position"] + ], + "value": "" + }, { + "id": "5a0d8747-9126-4b0a-9f09-7633873d663b", + "comment": "rendre email obligatoire", + "command": "", + "target": "", + "targets": [], + "value": "" + }, { + "id": "40bfa1d6-787e-4425-a7bf-7368592c5710", + "comment": "", + "command": "store", + "target": "Adresse E-Mail", + "targets": [], + "value": "libelle_champ" + }, { + "id": "5ff87d9d-3488-413a-9ce4-3e02e5ac8331", + "comment": "", + "command": "click", + "target": "xpath=//th[text()=\"${libelle_champ}\"]/following-sibling::td/a[contains(@href, \"edit.php\")]", + "targets": [ + ["css=tr:nth-child(1) > .actions span", "css:finder"], + ["xpath=//td[6]/a/span", "xpath:position"], + ["xpath=//span[contains(.,'Modifier')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "689edc49-7543-431e-ab21-2fce96160c86", + "comment": "", + "command": "selectFrame", + "target": "index=0", + "targets": [ + ["index=0"] + ], + "value": "" + }, { + "id": "ec8010b0-2996-4a81-b7c1-df06832e8a43", + "comment": "", + "command": "storeValue", + "target": "id=f_name", + "targets": [], + "value": "nom_champ" + }, { + "id": "866e8187-1914-4d84-8669-e459d3dad1cc", + "comment": "", + "command": "executeScript", + "target": "return 'f_' + ${nom_champ}", + "targets": [], + "value": "id_champ" + }, { + "id": "e8c797ac-c84b-47c2-bde8-d9dd81ec2d18", + "comment": "", + "command": "check", + "target": "id=f_required_1", + "targets": [], + "value": "" + }, { + "id": "27b23e0a-fa84-4025-aa15-61591693e9f8", + "comment": "", + "command": "click", + "target": "name=save", + "targets": [ + ["name=save", "name"], + ["css=.main", "css:finder"], + ["xpath=//button[@name='save']", "xpath:attributes"], + ["xpath=//p/button", "xpath:position"], + ["xpath=//button[contains(.,'Enregistrer')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "dfd4f600-3b65-4ffe-bf42-bf3391b05390", + "comment": "", + "command": "selectFrame", + "target": "relative=parent", + "targets": [ + ["relative=parent"] + ], + "value": "" + }, { + "id": "f20359c1-4113-4b80-98e3-6177d3098555", + "comment": "", + "command": "assertText", + "target": "xpath=//th[text()=\"${libelle_champ}\"]/following-sibling::td[2]", + "targets": [], + "value": "Obligatoire" + }, { + "id": "92fc2b11-24ea-4d0f-8175-245861ecb6e3", + "comment": "créer un membre", + "command": "", + "target": "", + "targets": [], + "value": "" + }, { + "id": "a2b6409c-e3b6-47ca-9cc7-32d761fe8b1f", + "comment": "", + "command": "click", + "target": "linkText=Ajouter", + "targets": [ + ["linkText=Ajouter", "linkText"], + ["css=li:nth-child(2) li:nth-child(1) > a", "css:finder"], + ["xpath=//a[contains(text(),'Ajouter')]", "xpath:link"], + ["xpath=//a[contains(@href, '/admin/users/new.php')]", "xpath:href"], + ["xpath=//li/a", "xpath:position"], + ["xpath=//a[contains(.,'Ajouter')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "a0d799de-342a-49eb-802d-72d1ce3cca95", + "comment": "", + "command": "//assertElementPresent", + "target": "xpath=//dt[contains(., \"${libelle_champ}\") and contains(., \"obligatoire\")]", + "targets": [], + "value": "" + }, { + "id": "506953b3-82d0-435e-b19e-0b8b8ee8a851", + "comment": "", + "command": "storeValue", + "target": "id=f_numero", + "targets": [], + "value": "numero" + }, { + "id": "e71e32dc-75ba-440c-9268-01704c9de8ca", + "comment": "", + "command": "executeScript", + "target": "const upper = (str) => { return str.charAt(0).toUpperCase() + str.slice(1);} ; const chaine = (length) => { let chars = 'aàbcdeéèfghijklmnoôpqrstuùvwxyz'; let str = ''; for (let i = 0; i < length; i++) { str += chars.charAt(Math.floor(Math.random() * chars.length)); } let debut = upper(str.slice(0, length/2)); let fin = upper(str.slice(length/2)); return debut + ' ' + fin;};return chaine(12)", + "targets": [], + "value": "nom" + }, { + "id": "3d93b965-c129-4b9d-8b84-33cb66d9bc7f", + "comment": "", + "command": "type", + "target": "id=f_nom", + "targets": [ + ["id=f_nom", "id"], + ["name=nom", "name"], + ["css=#f_nom", "css:finder"], + ["xpath=//input[@id='f_nom']", "xpath:attributes"], + ["xpath=//dd[3]/input", "xpath:position"] + ], + "value": "${nom}" + }, { + "id": "8529c004-d3c3-4c2c-bc2d-4b70ee0b92da", + "comment": "", + "command": "executeScript", + "target": "const chaine = (length) => { let chars = 'abcdefghijklmnopqrstuvwxyz0123456789'; let str = ''; for (let i = 0; i < length; i++) { str += chars.charAt(Math.floor(Math.random() * chars.length)); } return str; }; return chaine(8) + \"@\" + chaine(5) + \".fr\"", + "targets": [], + "value": "email" + }, { + "id": "478ce924-16c9-4b47-b6c4-2cad010e51bf", + "comment": "", + "command": "type", + "target": "id=f_email", + "targets": [ + ["id=f_email", "id"], + ["name=email", "name"], + ["css=#f_email", "css:finder"], + ["xpath=//input[@id='f_email']", "xpath:attributes"], + ["xpath=//dd[4]/input", "xpath:position"] + ], + "value": "${email}" + }, { + "id": "64ee0955-934a-4313-8a43-58a9b98e464a", + "comment": "", + "command": "click", + "target": "name=save", + "targets": [ + ["name=save", "name"], + ["css=.main", "css:finder"], + ["xpath=//button[@name='save']", "xpath:attributes"], + ["xpath=//p/button", "xpath:position"], + ["xpath=//button[contains(.,'Créer ce membre')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "f8ca78a5-9957-4614-b8cb-9dc05a7a81c1", + "comment": "vérifier infos membre", + "command": "", + "target": "", + "targets": [], + "value": "" + }, { + "id": "b06783fd-5330-42f9-a8e4-c068fb985e0e", + "comment": "", + "command": "assertText", + "target": "xpath=//dt[contains(.,'Numéro de membre')]/following-sibling::dd", + "targets": [], + "value": "${numero}" + }, { + "id": "975c2782-3b41-48c0-86ff-b3293775da8f", + "comment": "", + "command": "assertText", + "target": "xpath=//dt[contains(.,'Nom & prénom')]/following-sibling::dd", + "targets": [], + "value": "${nom}" + }, { + "id": "ba3e2027-90b0-45e5-9f88-b18b3f1152e9", + "comment": "", + "command": "assertText", + "target": "xpath=//dt[contains(.,'Adresse E-Mail')]/following-sibling::dd/a", + "targets": [], + "value": "${email}" + }, { + "id": "dead2236-14cb-43ba-8876-d3ad04729e52", + "comment": "remettre à l'état initial", + "command": "", + "target": "", + "targets": [], + "value": "" + }, { + "id": "73fc8a63-0529-4732-812e-d9d77c616b8f", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/\")]", + "targets": [ + ["css=li:nth-child(6) b", "css:finder"], + ["xpath=//li[6]/h3/a/b", "xpath:position"], + ["xpath=//b[contains(.,'Configuration')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "a7194d61-e11f-4c52-bdc3-3a9e4d524fac", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/users\")]", + "targets": [ + ["css=ul:nth-child(1) > li:nth-child(3) > a", "css:finder"], + ["xpath=//a[contains(text(),'Membres')]", "xpath:link"], + ["xpath=//a[@href='http://test.paheko.localhost/admin/config/users/']", "xpath:href"], + ["xpath=//nav/ul/li[3]/a", "xpath:position"] + ], + "value": "" + }, { + "id": "0fcd65f0-8bb4-4fb2-ac39-1ac29ec71f71", + "comment": "", + "command": "click", + "target": "xpath=//a[contains(@href, \"/admin/config/fields\")]", + "targets": [ + ["css=ul:nth-child(1) > li:nth-child(3) > a", "css:finder"], + ["xpath=//a[contains(text(),'Membres')]", "xpath:link"], + ["xpath=//a[@href='http://test.paheko.localhost/admin/config/users/']", "xpath:href"], + ["xpath=//nav/ul/li[3]/a", "xpath:position"] + ], + "value": "" + }, { + "id": "01676549-6a47-4a14-a889-4aaf0a5d7d50", + "comment": "", + "command": "click", + "target": "xpath=//th[text()=\"${libelle_champ}\"]/following-sibling::td/a[contains(@href, \"edit.php\")]", + "targets": [ + ["css=tr:nth-child(1) > .actions span", "css:finder"], + ["xpath=//td[6]/a/span", "xpath:position"], + ["xpath=//span[contains(.,'Modifier')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "d2a1f6a5-8f80-4a76-a024-7759f4aac1f8", + "comment": "", + "command": "selectFrame", + "target": "index=0", + "targets": [ + ["index=0"] + ], + "value": "" + }, { + "id": "5a02e960-119f-42de-ad50-3078b5eded73", + "comment": "", + "command": "uncheck", + "target": "id=f_required_1", + "targets": [], + "value": "" + }, { + "id": "3548edf0-f171-439a-9f75-3a47ef91fe2c", + "comment": "", + "command": "click", + "target": "name=save", + "targets": [ + ["name=save", "name"], + ["css=.main", "css:finder"], + ["xpath=//button[@name='save']", "xpath:attributes"], + ["xpath=//p/button", "xpath:position"], + ["xpath=//button[contains(.,'Enregistrer')]", "xpath:innerText"] + ], + "value": "" + }, { + "id": "bf7a0b90-5f5a-4e4e-8c26-205a45ada279", + "comment": "", + "command": "selectFrame", + "target": "relative=parent", + "targets": [ + ["relative=parent"] + ], + "value": "" + }, { + "id": "5d60ab40-b0fa-4fa4-bce5-808cd73a16f9", + "comment": "", + "command": "assertNotText", + "target": "xpath=//th[text()=\"${libelle_champ}\"]/following-sibling::td[2]", + "targets": [], + "value": "Obligatoire" + }] }], "suites": [{ "id": "6bdd4e16-7197-4388-9a5f-350523eb6c98", @@ -43797,7 +44190,7 @@ "persistSession": false, "parallel": false, "timeout": 300, - "tests": ["2414b9b6-6de9-4c5d-b120-30830eba1b2f", "b8768454-ae31-4cec-a902-45218cd2cd06", "38833b4a-62c8-4f5d-9865-8f38d1ee3994"] + "tests": ["2414b9b6-6de9-4c5d-b120-30830eba1b2f", "b8768454-ae31-4cec-a902-45218cd2cd06", "38833b4a-62c8-4f5d-9865-8f38d1ee3994", "2c1df50d-b2c8-4f68-92d5-8aaa5a45b4de"] }], "urls": ["http://test.paheko.localhost/"], "plugins": []