How do I suppress webkit messages in rspec output

佐手、 提交于 2019-12-11 14:56:59

问题


I've just moved to a macbook pro retina with Mavericks and have started getting these warning messages in my rspec output:

webkit_server[55708:507] CoreText performance note: Client called CTFontCreateWithName() using name "Arial" and got font with PostScript name "ArialMT". For best performance, only use PostScript names when calling this API.

I'm using capybara with the webkit javascript driver by setting the following in my spec_helper.rb file:

Capybara.javascript_driver = :webkit

Does anyone know how to suppress the messages?


回答1:


you can do this

brew uninstall qt && brew update && brew install qt

related: https://github.com/thoughtbot/capybara-webkit/issues/581




回答2:


Just answering my own question here after finding some info from github:

This seems to be an issue seen specifically on Mavericks and is todo with one of capybara-webkit's dependancies; the capybara-webkit project are aware of it and currently have a work around available in this issue discussion thread

One thing to note is that the work around didn't work for me on capybara-webkit 0.14.2 so I updated to version 1.0.0 with:

bundle update capybara-webkit

The message suppession routine work fine after that :)



来源:https://stackoverflow.com/questions/19732508/how-do-i-suppress-webkit-messages-in-rspec-output

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!