You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I'm having trouble with the next command and I'm not sure if I'm misunderstanding how it is supposed to work or if there is a bug.
From the documentation I would assume that next takes you to the next line after the one we are currently on:
n[ext]
Step over. Resume the program until next line.
But, for example, in a Capybara-spec running in rspec I get the following behaviour:
# it "does some things" do
# > click_on("Some button")
# select("Something", from: "A list")
# expect(page).to have_content("A result")
# end
(rdbg) next
[27, 36] in ~/.local/share/gem/ruby/3.2.0/gems/capybara-3.40.0/lib/capybara/result.rb
27|
28| def initialize(elements, query)
29| @elements = elements
30| @result_cache = []
31| @filter_errors = []
=> 32| @results_enum = lazy_select_elements { |node| query.matches_filters?(node, @filter_errors) }
33| @query = query
34| @allow_reload = false
35| end
36|
=>#0 block {|node=#<Capybara::Node::Element tag="button" pa...|} in initialize at ~/.local/share/gem/ruby/3.2.0/gems/capybara-3.40.0/lib/capybara/result.rb:32
#1 [C] Array#each at #<none>:0
# and 3 frames (use `bt' command for all frames)
Instead of going to the next line it breaks in a (seemingly) random place inside of the Capybara gem.
I'm not sure if this only happens with Capybara but I think I had similar problems before – but maybeI just did not understand what was happening at all back then and there were different things going on.
Is this expected behaviour for next? If so: why? And if not: What do you need for a full bug report?
Thanks in advance for your help and for your work on this in general!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi, I'm having trouble with the
next
command and I'm not sure if I'm misunderstanding how it is supposed to work or if there is a bug.From the documentation I would assume that
next
takes you to the next line after the one we are currently on:But, for example, in a Capybara-spec running in
rspec
I get the following behaviour:Instead of going to the next line it breaks in a (seemingly) random place inside of the Capybara gem.
I'm not sure if this only happens with Capybara but I think I had similar problems before – but maybeI just did not understand what was happening at all back then and there were different things going on.
Is this expected behaviour for
next
? If so: why? And if not: What do you need for a full bug report?Thanks in advance for your help and for your work on this in general!
Beta Was this translation helpful? Give feedback.
All reactions