FluentLenium

6,533
-1

Published on

Published in: Technology
1 Comment
5 Likes
Statistics
Notes
No Downloads
Views
Total Views
6,533
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
41
Comments
1
Likes
5
Embeds 0
No embeds

No notes for slide

FluentLenium

  1. 1. FluentLenium,une autre façon de faire du selenium by Mathilde Lemée @MathildeLemee 1
  2. 2. Mathilde Lemée@MathildeLemee 2
  3. 3. Selenium 3
  4. 4. FluentLenium 4
  5. 5. 1. Optimiser lécriture 5
  6. 6. Selectors CSS > XPath• find("#monId")• find(".maClass")• find("maBalise")• find("input[class=rightForm]") 6
  7. 7. Custom Selectors• find(".small", withName("foo"))• find(".small", withId("idOne"))• find(".small", withText("This field")• find(".small", withId().notStartsWith("id"))• find(".small", withName().contains(regex("na?me[0-9]*")) 7
  8. 8. Selectors• findFirst(myCssSelector)• find(myCssSelector, 2)• find(myCssSelector, 2, withName("foo"))• find(myCssSelector, 2, withName("foo")).find("input", withName("bar")) 8
  9. 9. II. Faciliter les interactions 9
  10. 10. Actions• click("#create-button")• clear("#firstname")• submit("#account")• fill("#firstname").with("Mathilde")• find("#monId").click()• executeScript("alert(Devoxx);"); 10
  11. 11. III. Garantir la maintenance 11
  12. 12. 12
  13. 13. // If youre reading this, that means you havebeen put in charge of my previous project.// I am so, so sorry for you. God speed. 13
  14. 14. Page Object Pattern 14
  15. 15. 15
  16. 16. 16
  17. 17. IV. Améliorer la gestion AJAX 17
  18. 18. 18
  19. 19. 19
  20. 20. 20
  21. 21. V. Simplifier les assertions 21
  22. 22. 22
  23. 23. VI. Jquery Style 23
  24. 24. 24
  25. 25. Merci @MathildeLemeehttp://www.fluentlenium.org 25

×