News for hackers. Stuff that matters.
Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by JackC on Thursday December 03, 2020 @11:29AM (#25290595)
I'm really excited by what Playwright has been up to on the python side recently with the pytest-playwright package. Browser-testing a Django app can be as simple as:

  def test_homepage(live_server, page):
      page.goto(live_server.url)
      assert page.innerText('#splash-quote') == 'our splash-quote'
  
  $ pytest -k test_homepage --browser chromium --browser firefox --verbose
  tests/test_browser.py::test_homepage[chromium] PASSED                [ 50%]
  tests/test_browser.py::test_homepage[firefox] PASSED                 [100%]
Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by samdamsamma on Saturday December 05, 2020 @02:44AM (#25312680)
It would be neat if I could get coverage from these tests using python, but other than that I agree. Playwright is great.
Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by WalterGR on Thursday December 03, 2020 @09:49PM (#25298354)
It’s been some time since I’ve used Selenium, but I don’t remember it being any more complicated than that to test arbitrary websites.

What is that code doing that’s special?

Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by sharmi on Thursday December 03, 2020 @10:29PM (#25298557)
Not OP. For one thing, Selenium was not super reliable, at least for me, especially when trying to run multiple instances. Do note that I used the official docker swarm method.

When I was exploring that option, Playwright was still windows only. Super excited to see it is available on Linux and Mac.

Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by arjun27 on Thursday December 03, 2020 @10:42PM (#25298623)
Playwright has always supported all platforms: Win, Linux and Mac. Is there something that didn’t work for you?
Re:Benchmark: Puppeteer vs. Selenium vs. Playwright vs. WebD... by sharmi on Thursday December 03, 2020 @10:58PM (#25298718)
Maybe it didn't have python support? Sorry, I may have misremembered. I do remember something missing that I couldn't use it in my existing dev setup. As solo developer, I prefer to keep my dependencies minimal, mostly python.