大佬教程收集整理的这篇文章主要介绍了ruby-on-rails – Capybara,Poltergeist和Reactjs – ‘undefined’不是函数,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
这是测试的堆栈:
>黄瓜
>水豚
>恶作剧者(通过phantomjs)
> Rspec
例如,有黄瓜功能:
@javascript @services Feature: Manage service Scenario Outline: Publish and archieve Given the individual user When I visit services page And I click on I18n translation for key "views.labels.add" And I fill service's fields and choose price as "<price>" And I click on I18n translation for key "<submiT_Btn>" Then I should see I18n translation for key "<message>" And Created service should have 1 tag Examples: | submiT_Btn | price | message | | views.labels.publish | fixed | views.messages.notices.add.created | | views.labels.publish | negotiated | views.messages.notices.add.created |
当我运行此测试时,我看到此错误:
One or more errors were raised in the Javascript code on the page. If you don't care about these errors,you can ignore them by setTing js_errors: false in your Poltergeist configuration (see documentation for details). TypeError: 'undefined' is not a function (evaluaTing 'RegExp.prototype.test.bind( /^(data|aria)-[a-z_][a-z\d_.\-]*$/ )') TypeError: 'undefined' is not a function (evaluaTing 'RegExp.prototype.test.bind( /^(data|aria)-[a-z_][a-z\d_.\-]*$/ )') at http://127.0.0.1:53686/assets/application.js:32342 at http://127.0.0.1:53686/assets/application.js:28807 in s at http://127.0.0.1:53686/assets/application.js:28807 at http://127.0.0.1:53686/assets/application.js:37581 at http://127.0.0.1:53686/assets/application.js:28807 in s at http://127.0.0.1:53686/assets/application.js:28807 at http://127.0.0.1:53686/assets/application.js:32910 at http://127.0.0.1:53686/assets/application.js:28807 in s at http://127.0.0.1:53686/assets/application.js:28807 in e at http://127.0.0.1:53686/assets/application.js:47260 at http://127.0.0.1:53686/assets/application.js:28807 at http://127.0.0.1:53686/assets/application.js:47262 (Capybara::Poltergeist::JavascriptError) ./features/step_definitions/service.steps.rb:16:in `/^the individual user$/' features/service/new.feature:9:in `Given the individual user'
以上是大佬教程为你收集整理的ruby-on-rails – Capybara,Poltergeist和Reactjs – ‘undefined’不是函数全部内容,希望文章能够帮你解决ruby-on-rails – Capybara,Poltergeist和Reactjs – ‘undefined’不是函数所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。