Bug 243827 - Toggle Method Breakpoint menu item does not work
Summary: Toggle Method Breakpoint menu item does not work
Status: NEW
Alias: None
Product: DLTK
Classification: Technology
Component: Common-Debug (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: dltk.common-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-11 20:12 EDT by Atsushi Hasegawa CLA
Modified: 2012-01-18 07:36 EST (History)
2 users (show)

See Also:


Attachments
Q7 test for testing of this case (26.50 KB, application/octet-stream)
2012-01-18 06:06 EST, Nastya Ahramenko CLA
no flags Details
Q7 test for testing of this case (26.50 KB, text/plain)
2012-01-18 06:30 EST, Nastya Ahramenko CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Atsushi Hasegawa CLA 2008-08-11 20:12:29 EDT
1. Start new workspace

2. Create a ruby project
File | New | Project...
< Ruby / Ruby Project >
< Next > >
< Project name: [DebugRuby] >
< Finish >

3. Create a Ruby Class
File | New | Ruby Class
< File: [MyClass2] > 
< Finish >

4. Paste the following snippet on the MyClass2.rb file.

5. Open [Breakpoints] view in [Debug] perspective
Window | Open Perspective | Debug
< Breakpoints > // Select view on the perspective.
< Remove All Breakpoints > // If some breakpoint exists from previous test
cases.

6. Set method breakpoint
< line 21 > // Place caret position in printVariables() method at line 21.
> localVariable = "localVariable3"
Run | Toggle Method Breakpoint // Select from main menu bar.

// exp: printVariables() method breakpoint is added on the [Breakpoints] view.
// act: Following [Toggle Method Breakpoint] dialog is displayed, even if
cursor position is inside of printVariables() method.
> The operation is unavailable on the current selection. Please place the cursor inside a method.


# Test snippet 6747 for debug test
$globalVariable = "globalVariable1"
CONSTANT = "CONSTANT1"
class MyClass2
  localVariable = "localVariable1"
  @instanceVariable = "instanceVariable1"
  @@classVariable = "classVariable1"
# Set a breakpoint at next line
  p $globalVariable
  p CONSTANT
  p localVariable
  p @instanceVariable
  p @@classVariable
  p self
  def initialize
    localVariable = "localVariable2"
    @instanceVariable = "instanceVariable2"
    @@classVariable = "classVariable2"
  end
  def printVariables
    localVariable = "localVariable3" # Place caret position at step 6.
    p "In printVariables"
    p $globalVariable
    p CONSTANT
    p localVariable
    p @instanceVariable
    p @@classVariable
    p self
  end
end
# Set a breakpoint at next line
MyClass2.new.printVariables
p self
# End of snippet 6747
Comment 1 Nastya Ahramenko CLA 2012-01-18 06:06:07 EST
Created attachment 209666 [details]
Q7 test for testing of this case
Comment 2 Nastya Ahramenko CLA 2012-01-18 06:30:56 EST
Created attachment 209670 [details]
Q7 test for testing of this case
Comment 3 Alex Panchenko CLA 2012-01-18 07:34:17 EST
@Nastya this bug belongs to Ruby component, so it is strange to have .js files in the test.
Comment 4 Andrey Platov CLA 2012-01-18 07:36:31 EST
The bug is everywhere - changing component to common-debug