Capybara Webkit very slow?

685 views
Skip to first unread message

David Kennedy

unread,
Mar 16, 2012, 11:49:15 AM3/16/12
to capybara-webkit
I'm using RSpec with Capybara Webkit, but I'm seeing veeeery slow
tests, with an average of 12 seconds for a single test! From my
reading, this is much slower than should be expected. Debugging /
profiling this is very frustrating, does anyone have any advice? Is
this a known issue?

This is on an Ubuntu machine, and I wonder if it's related to
https://github.com/thoughtbot/capybara-webkit/issues/41

Moreno Carullo

unread,
Mar 20, 2012, 5:53:19 AM3/20/12
to capybar...@googlegroups.com
Maybe you could check external resources on your pages (e.g. extremely slow advertising, for example).

-- Moreno

Patrick Bacon

unread,
Mar 23, 2012, 12:27:57 PM3/23/12
to capybar...@googlegroups.com
I am also seeing slowness on Ubuntu. I have a test that does hundreds of page.find and element.text calls on a very large page. The test takes about 45 seconds on my MacBook Pro, but close to 15 minutes on a very fast Ubuntu machine.

No external resources are being loaded on the page. I have not spent much time investigating it yet, but it looks like finding elements on a large page is very slow on Ubuntu.

I was able to speed things up a bit by explicitly setting:

Capybara.automatic_reload = false

 - Patrick

Marc Remolt

unread,
Apr 17, 2012, 6:42:18 AM4/17/12
to capybara-webkit
Same problem on my Ubuntu machine.

I noticed that the webkit_server process seems to be sleeping most of
the time while running the features.

On my Intel I3 this process averages around 5% CPU in top.

So either something inside this process is blocking, or it doesn't
receive work fast enough.

Maybe this helps a bit.

Cheers,
Marc

Ajedi32

unread,
Oct 31, 2012, 5:01:50 PM10/31/12
to capybar...@googlegroups.com
I am experiencing a similar problem on Windows:

Visiting a page (one step):
    user     system      total        real
1.719000   2.688000   4.407000 ( 44.955124)

Yuri R.

unread,
Jan 15, 2013, 1:12:28 AM1/15/13
to capybar...@googlegroups.com
Hello, did you solved this problem? I have the same on my Ubuntu machine, but on Mac it runs 3 times faster...

пятница, 16 марта 2012 г., 23:49:15 UTC+8 пользователь David Kennedy написал:

Igor Dobryn

unread,
Apr 11, 2013, 2:31:37 AM4/11/13
to capybar...@googlegroups.com, david....@examtime.com
Any decisions guys? For me it 50% slower on Ubuntu than on Mac OS.    
Reply all
Reply to author
Forward
0 new messages