+1
yes this is very good. returning null always has so many annoying
side-effects
Florian Hehlen
-----Original Message-----
From: edoardo.comar
Sent: 24 January 2002 18:03
To: eap-features
Cc: edoardo.comar
Subject: RE: [Eap-features] Test-First Design - Need a forward code
completion or code generation.
Ariadna will have that.
As for stubs generation though, I'd very much prefer that the methods do
throw new java.lang.UnsupportedOperationException("TODO");
(perhaps with a customizable message to make everyone happy)
rather than return dummy values (0, null ....)
Edo
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]] On Behalf Of Jacques Morel
> Sent: 24 January 2002 16:39
> To: [EMAIL PROTECTED]
> Subject: [Eap-features] Test-First Design - Need a forward
> code completion or code generation.
>
>
> I am sure all of you are familiar with eXtreme Programming
> practice Test-First Design. This practice promotes the use of
> unit tests as a way to flesh out the interface of a class and
> make that class testable by design and very user friendly. In
> other words you write one test case then make it compile by
> coding a stub version of the class under test then you make
> the test pass by fleshing the content of the stubbed
> method(s). The unfortunate side effect of this is your unit
> test doesn't compile until you have gone to the next step and
> created the stubs. The current code completion doesn't help
> and is not usable.
> I would call this backward code completion where the
> completion is done against something that is already done.
>
> To help Test-First design you need another kind of
> completion. I will call it "forward completion". While
> writing my test, as I introduce a use of a new interface of
> the class under test I can trigger the generation of a
> corresponding compilable stub. The method generation would
> use the type of the lhs of the call to determine the return
> type and would use the call arguments type to determine the
> function parameter types. If the function has a return type a
> dummy value would be returned (0 or null). I am not sure we
> need the generation of data members but it could follow the
> same process.
>
> No other IDE has support for this Test-First or Top-Down
> design approach. This could rally a lot of XP people under IntelliJ!
>
> Jacques Morel
> Sr. Application Architect
> nextjet
> mailto:[EMAIL PROTECTED]
> (214) 292-3273
>
>
>
>
>
> _______________________________________________
> Eap-features mailing list
> [EMAIL PROTECTED]
> http://www.intellij.com/mailman/listinfo/eap-> features
>
>
_______________________________________________
Eap-features mailing list
[EMAIL PROTECTED]
http://www.intellij.com/mailman/listinfo/eap-features
Visit our website at http://www.ubswarburg.com
This message contains confidential information and is intended only
for the individual named. If you are not the named addressee you
should not disseminate, distribute or copy this e-mail. Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.
E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses. The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission. If
verification is required please request a hard-copy version. This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.
_______________________________________________
Eap-features mailing list
[EMAIL PROTECTED]
http://www.intellij.com/mailman/listinfo/eap-features