Search the web
Sign In
New User? Sign Up
testdrivendevelopment · Test-driven Development
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
The first test - Hardest part about TDD?   Message List  
Reply | Forward Message #28274 of 32012 |
Re: [TDD] Re: The first test - Hardest part about TDD?

I think the answers of "solve A first" show succinctly that a large
proportion of minimising refactoring in TDD (and in any code) is
experience ... the sooner you can see these things coming up (before
you code them), the earlier you will approach the problem to avoid
wasting time going down routes that will ultimately be refactored out.

And the analogy with scaffolding for a house is an excellent one -
there is a lot of "stuff" constructed when building a house, *just* to
support the construction - it is then discarded.

2008/5/23 Sriram Gopalan <mgsram@...>:
> I fully agree.
> Solve A. Ideally a & b would be contained within A and you may or may not
> have to refactor them out. May be you would refactor a _c_ out :-). Also
> note that you need to keep the whole test suite green. Therefore, no way you
> could get wrong with the algorithm that is A.
>
> -Sriram
>
> On Thu, May 22, 2008 at 6:59 PM, George Dinwiddie <lists@...>
> wrote:
>
>> Olof Bjarnason wrote:
>> > @Matt, @John and @Ron.
>> >
>> > Say I want to solve a problem A.
>> >
>> > With my experience, I can visualize a solution consisting of two
>> > subproblems a and b, two "helper classes" of A.
>> >
>> > I try to solve a first.
>>
>> Solve A first. Perhaps the a and b you envision will appear in that
>> solution and perhaps not. It surprises me how often not.
>>
>> - George
>>
>> --
>> ----------------------------------------------------------
>> * George Dinwiddie * http://blog.gdinwiddie.com
>> Software Development http://www.idiacomputing.com
>> Consultant and Coach http://www.agilemaryland.org
>> ----------------------------------------------------------
>>
>>
>>
>
> [Non-text portions of this message have been removed]
>
>



Fri May 23, 2008 6:20 am

caseycharlton69
Offline Offline
Send Email Send Email

Forward
Message #28274 of 32012 |
Expand Messages Author Sort by Date

I fully agree. Solve A. Ideally a & b would be contained within A and you may or may not have to refactor them out. May be you would refactor a _c_ out :-)....
Sriram Gopalan
mgsram
Offline Send Email
May 23, 2008
1:17 am

I think the answers of "solve A first" show succinctly that a large proportion of minimising refactoring in TDD (and in any code) is experience ... the sooner...
Casey Charlton
caseycharlton69
Offline Send Email
May 23, 2008
6:20 am

... Casey, I think that experience is always helpful in getting something right the first time. And that experience is earned by getting things wrong many...
George Dinwiddie
gdinwiddie
Offline Send Email
May 23, 2008
1:39 pm

Hello John, When you created tests for * - set text - click button - expect other text * I m curious as to what was the object under test ? I have been TDDing...
Sriram Gopalan
mgsram
Offline Send Email
May 22, 2008
11:58 am

Sriram, I guess the nearest concept under test would be 'view'. But, in fact I wrote something like: WidgetForm wf = new WidgetForm(); Wf.QuestionText = "xyz";...
Donaldson, John (GEO)
geo_johnfr
Offline Send Email
May 22, 2008
12:16 pm

Andreas, I too struggle with "the first test". Maybe you should adopt a "start anywhere" approach - just to get started - with the expectation that you'll...
Donaldson, John (GEO)
geo_johnfr
Offline Send Email
May 22, 2008
7:41 am

This brings up something I've been wondering how people approach. Do you often start with frameworks for your applications when doing TDD, or do you refactor...
Peter Bell
freshstartsw
Online Now Send Email
May 22, 2008
9:58 am

... If the point of the project was to build a viewer, I might start with the GUI. Otherwise I always start with the model. I'd never impose a pattern in...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 22, 2008
11:21 am

Interesting. When I build web apps I always start with the views and then build just enough of a model to make the views work. I've found in the past that when...
Peter Bell
freshstartsw
Online Now Send Email
May 22, 2008
11:27 am

... Like Ron, I typically start with the model. But not necessarily the "business model" that I assume should exist, but the "display model" of what will...
George Dinwiddie
gdinwiddie
Offline Send Email
May 22, 2008
2:40 pm

Ron, Yes, in this case it's a sort of viewer. Let's say widget viewer. But finally there'll be widgets, widget collections, things to manage widgets, widget...
Donaldson, John (GEO)
geo_johnfr
Offline Send Email
May 22, 2008
11:49 am

I suppose we could also call the scaffold we use when constructing a large building as waste, or the safety harnesses as waste. One useful distinction I've...
John Roth
jhrothjr
Offline Send Email
May 22, 2008
1:58 pm

... I see I am beaten to the punch. ... J. B. (Joe) Rainsberger :: http://www.jbrains.ca Your guide to software craftsmanship JUnit Recipes: Practical Methods...
J. B. Rainsberger
nails762
Offline Send Email
May 27, 2008
2:51 pm

Hello, Andreas. Let me babble a bit about what I do and what your words remind me of. On Monday, May 19, 2008, at 5:30:39 AM, you ... Sometimes I might decide...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 22, 2008
1:59 pm

... Do you use mocks at all? I tend to find that I use mocks fairly extensively (or rather a mocking framework) in my unit tests for database interactions,...
Peter Bell
freshstartsw
Online Now Send Email
May 22, 2008
2:31 pm

Hello, Peter. On Thursday, May 22, 2008, at 10:31:45 AM, you ... I don't use mocks per se, esp in the specific formal sense of an object that pays attention...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 22, 2008
5:51 pm

Hello Ron, /Second, as PresenterFirst Presenters essentially have no interface, it's really hard to write a test for it. So I might be inclined to write a sort...
Sriram Gopalan
mgsram
Offline Send Email
May 22, 2008
6:39 pm

Hello, Sriram. On Thursday, May 22, 2008, at 2:39:44 PM, you ... Sounds right to me. If you can call the public methods directly, that's what I'd be providing...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 22, 2008
8:05 pm

... I disagree. In http://www.atomicobject.com/files/BigComplexTested_Feb07.pdf, where I first got into contact with PF, the technique is introduced from a...
Andreas Krügersen
wyverex42
Offline Send Email
May 22, 2008
9:01 pm

... Andreas, can you point out the TDD in this article? I scanned through it twice and didn't spot any tests at all. I'm wondering if perhaps we mean...
George Dinwiddie
gdinwiddie
Offline Send Email
May 22, 2008
11:12 pm

... George, you're right about not spotting any test as a code snippet. All examples included in the article are production code. But the references to testing...
Andreas Krügersen
wyverex42
Offline Send Email
May 23, 2008
4:19 pm

Hello, Andreas. On Friday, May 23, 2008, at 12:19:31 PM, you ... I didn't read terribly carefully but I didn't notice tests in that article either ... Ron...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 23, 2008
4:38 pm

... I don't value the article by its amount of code examples. It's all in the text along with an algorithm of how to do presenter first development writing...
Andreas Krügersen
wyverex42
Offline Send Email
May 23, 2008
4:58 pm

Hello, Andreas. On Friday, May 23, 2008, at 12:57:08 PM, you ... If I understood your question, you yourself had some difficulty writing the early tests for a...
Ron Jeffries
ronaldejeffries
Offline Send Email
May 23, 2008
5:34 pm

... I can tell you that I test-drive plenty of web application features presenter-first and I find it to be a lovely way to work. You don't / have/ to use mock...
J. B. Rainsberger
nails762
Offline Send Email
May 27, 2008
2:54 pm

The trouble with recognizing things such as scaffolding as "waste" is that you can then recognize everything other than the final product as waste. The only...
John Roth
jhrothjr
Offline Send Email
May 27, 2008
6:22 pm

John, ... Maybe recognizing that kind of waste is the genesis of innovation? I mean, if I could figure out a way to build a building with the wave of a ...
Matt
maswaffer
Offline Send Email
May 27, 2008
7:15 pm

... I wonder how many inventions through history has come into being because of people questioning the reasons for inefficiencies in "current affairs". I think...
Olof Bjarnason
olof.bjarnason@...
Send Email
May 27, 2008
7:26 pm

... Having such a definition allows us to measure improvement. Having a definition for "waste" also suggests that we need one for "risk," so that we can...
Jeff Langr
jlangr
Offline Send Email
May 27, 2008
8:38 pm

... Jeff, I wonder if those same organizations count debug time as waste! 8^) GB....
Gary Brown
gb70840
Offline Send Email
May 27, 2008
8:59 pm
 First  |  |  Last 
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help