views:

210

answers:

2

I think some shortcut to create a method stub in eclipse might be useful. Does anyone know how to do it?

+1  A: 

Type public_method (see Java/Editor/Templates in preferences for more options) or method name and press ctrl+space.

Ha
Thanks, and would you by any chance know of other shortcuts that could be helpful when trying TDD?
Abhijeet Kashnia
Nope. I do not have a project where I can try TDD because they have custom UI components, run inside large framework, use heuristic, numerical or impossible-to-calculate-by-hand algorithms what makes them impossible to test.
Ha
+2  A: 

Type your method name and hit ctrl+space.

Also worth noting is, type 'test' and hit ctrl+space and it will give you the option to create a test method stub.

Mike
Thanks, that was useful.
Abhijeet Kashnia