Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
 
 
 
 

52 rader
1.3 KiB

  1. describe("initial render", function () {
  2. let mainPage
  3. describe("for topbar", function () {
  4. let topbar
  5. before(function (client, done) {
  6. done()
  7. })
  8. after(function (client, done) {
  9. client.end(function () {
  10. done()
  11. })
  12. })
  13. afterEach(function (client, done) {
  14. done()
  15. })
  16. beforeEach(function (client, done) {
  17. mainPage = client
  18. .url("localhost:3230")
  19. .page.main()
  20. topbar = mainPage.section.topbar
  21. client.waitForElementVisible(".download-url-input:not([disabled])", 10000)
  22. .clearValue(".download-url-input")
  23. .setValue(".download-url-input", "http://localhost:3230/test-specs/petstore.json")
  24. .click("button.download-url-button")
  25. .pause(1000)
  26. done()
  27. })
  28. it("renders section", function (client) {
  29. mainPage.expect.section("@topbar").to.be.visible
  30. client.end()
  31. })
  32. it("renders input box", function (client) {
  33. topbar.expect.element("@inputBox").to.be.visible
  34. client.end()
  35. })
  36. it("renders explore button", function (client) {
  37. topbar.expect.element("@btnExplore").to.be.visible
  38. client.end()
  39. })
  40. })
  41. })