Commit Graph

28 Commits

Author SHA1 Message Date
Thomas Walpole 047098ad3f Disable jruby lazy results evaluation again 2017-02-16 13:34:45 -08:00
Thomas Walpole f7e537006a allow lazy results evaluation on JRuby 9.1.6.0+ 2016-12-27 11:03:04 -08:00
Akira Matsuda 6805707da5 ⚠️ `&' interpreted as argument prefix 2016-11-03 22:22:34 +09:00
Thomas Walpole 4bd9806804 Capybara::Result#each returns an Enumerator when called without a block 2016-10-18 11:15:25 -07:00
Thomas Walpole ff51c95e76 Change how app errors are raised so cause gets set as wanted in JRuby
JRuby has an issue with lazy enumerator evaluation - disable Capybara::Result optimization when using JRuby
  See: https://github.com/jruby/jruby/issues/4212
2016-10-07 17:14:30 -07:00
Thomas Walpole cb85ed5d13 optimize Result#matches_count? 2016-08-31 14:55:03 -07:00
Thomas Walpole 5033eca9fc move helpers to BaseQuery 2016-08-31 12:04:22 -07:00
Thomas Walpole 676fba48e2 Optimize Capybara::Result by evaluating filters lazily when possible 2016-08-15 13:28:32 -07:00
Thomas Walpole 07e7777425 frozen literal magic comment 2016-03-07 16:52:19 -08:00
Eoin Kelly 988a4f7acc Fix API doc references to non-existent Capybara::Element 2015-02-27 07:05:39 +13:00
Andrey Botalov 06c4955e56 Use diffferent queries for searching
* Add assert_text, assert_no_text, assert_title, assert_no_title
* Refactor query resolving
* Improve failure messages for have_text, have_title RSpec matchers (they will be the same as for added assert_* methods)
* Add Simple#inspect
2014-07-01 23:13:45 +03:00
Andrey Botalov 4df077e375 Delegate index and values_at from Capybara::Result 2013-10-29 23:43:11 +03:00
Phil Lee b9c88ee2a1 Results can now be sampled.
An instance of Result can now call #sample. This is delegated to Array#sample.
This allows a random result to be chosen.
This is useful if we want to check one of the results but with no particular preference as to which result.
2013-09-16 12:19:06 +01:00
Sam Rawlins 1f97459fc5 Added #inspect to the delegators 2013-07-24 11:55:17 -07:00
Jonas Nicklas 415e2db70d Refactor and document 2013-03-17 15:48:04 +01:00
Andrey Botalov 3783237c5f Add count options to has_text 2013-03-04 02:04:23 +03:00
Jonas Nicklas e330e88a5e Merge branch 'capy21'
Conflicts:
	spec/basic_node_spec.rb
2013-02-15 22:53:15 +01:00
Jonas Nicklas e898cc2b8e Add `match` option 2013-02-15 21:32:21 +01:00
Matt Greenfield 68fd350bb1 Adding documentation for Capybara::Result to be more explicit about what
Node#all returns.
2013-01-28 18:58:15 -05:00
Jonas Nicklas 5c79469259 Merge pull request #782 from ineverov/size_instead_of_count
Use size instead of count
2012-08-30 07:24:25 -07:00
adammck 86bcb24071 Delegate common Result methods to Array
Closes upstream #784.
2012-08-09 20:54:59 -04:00
Ivan Neverov 4824afae6c Use size instead of count 2012-08-08 18:02:48 -05:00
Jonas Nicklas 28aa12ca50 Further improve error messages 2012-07-09 14:47:11 +02:00
Jonas Nicklas 6bccbad114 Slightly better stock errors 2012-07-09 13:33:45 +02:00
Jonas Nicklas b8af344659 Added ambiguous error 2012-07-09 13:21:44 +02:00
Jonas Nicklas f57a36d2fe Add [] method to Capybara results 2012-06-11 17:24:50 +02:00
Jonas Nicklas and Nicklas Ramhöj 5935b6c052 Use HaveSelector matchers for more RSpec matchers 2012-06-08 17:07:12 +02:00
Jonas Nicklas and Nicklas Ramhöj 66b6aed8b2 Move failure message generatio to result class 2012-06-08 16:47:01 +02:00