This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 158147 - Shoulda test navigation
Summary: Shoulda test navigation
Status: RESOLVED FIXED
Alias: None
Product: ruby
Classification: Unclassified
Component: Testing (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Erno Mononen
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-02-08 11:39 UTC by nigel_bris
Modified: 2009-04-27 15:34 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description nigel_bris 2009-02-08 11:39:46 UTC
If you double click on a failed Shoulda test (in the left pane of Test Results) it normally navigates you to the failed assert line. With Shoulda tests it opens the 
file "test_process.rb" or "validations.rb".
Comment 1 Erno Mononen 2009-02-09 09:41:05 UTC
Could you please attach an example test case where this happens? In my tests it works as expected, but I have only a 
handful of shoulda tests that I use for testing the support.
Comment 2 nigel_bris 2009-02-09 13:03:28 UTC
I cannot reproduce this now.... Sorry!
Comment 3 Erno Mononen 2009-02-10 12:45:48 UTC
No prob, just ping here when you run into this again.
Comment 4 nigel_bris 2009-02-15 12:49:14 UTC
Found it....

should "test" do
  assert some_var
end

some_var is not defined so its an error... double click on the failed test result it opens "test_process.rb". Tested with:
def test_me
  assert some_var
end
and it does navigate within the test file, which means its specific to shoulda...

Will keep looking for issue that causes "validation.rb" file to open....


Comment 5 nigel_bris 2009-02-15 13:24:38 UTC
extra:
Found another (probably related) controller test:-
should "test" do
  get :unknown_action
end
Run test and get.. ActionController::RoutingError: No route matches {:controller=>"a_controller", :action=>"unknown_action"}

Double click on failed test result opens "route_set.rb"

Comment 6 Erno Mononen 2009-02-17 08:22:40 UTC
Thanks, I'm able to reproduce now.
Comment 7 Erno Mononen 2009-02-17 11:14:58 UTC
Should be fixed now in dc11ff7f3931, it'll however take some time before I can push it as we're just creating a clone 
for M2 (there'll be a notification here when the fix makes it to the build). While testing I noticed some problems with 
navigating to passed shoulda tests though, so I'm leaving this open until I resolve those too.
Comment 8 nigel_bris 2009-02-17 21:21:44 UTC
Hi Erno, I added #158581 a couple of days ago with another navigation issue.
Comment 9 Erno Mononen 2009-02-18 11:43:52 UTC
Ah, I had missed that somehow. I'll take a look at it.
Comment 10 Quality Engineering 2009-02-22 07:53:19 UTC
Integrated into 'main-golden', will be available in build *200902220201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/dc11ff7f3931
User: Erno Mononen <emononen@netbeans.org>
Log: #158147: Shoulda test navigation
Comment 11 Erno Mononen 2009-04-27 15:34:35 UTC
Apparently I forgot to mark this as fixed (should be fixed by dc11ff7f3931).