I'm still trying to create our application. I was doing our
nunit with the idea I've explain
here. And now, I'm not really so sure about it...
I'm not sure that's the way you should do things not at all. I'm even thinking that is a bad way of doing things... I must explain why... You gonna see it's easy why. If you think about the three lines of code the developer should do it, that means you think for the end user. And THAT is wrong.
The other thing that bother me is the following thing. If the three lines force me to a bad design, I have to refactor it. How many time I have to do this to make a good design. Let me give you an example: Our application take the RSS feed of Ocinine to get the information we need. Everyone now that a feed have one channel and one or more item(each post). If (
I don't know how) my three lines of code give me something that look like I need one or more channel and only one item, I'm gonna have a problem.
I know, your not that so stupid. How can three lines of code can make me do something like this? Thats not the point. I understand why they tell this (You should make thing simple for the developper) But I think now you should do the otherway. I think (after doing some of our unit test, and i'm a developper to with another
framework) That we really should start with the core of our Application and do a "spiral" around youre core class. Doing this, you could really finish some part of your app.
If you start with the finishing three lines, how can you tell when your application is finish? Is it when your three lines of code are working? You could do better then that. If you need to had some new stuff, what do you do? Write three other lines or change your first ones? If your new stuff create a bug in the old lines, what do you do?
Thats why I think you should first design the core of your application and then, write the three lines the developper will have to write.
Oh, I even have a better way then that, never write the line the developper gonna need. That's the concept of all new Java Framework (Spring, hibernate, JSF). The developper should do it's code like your framework doesn't exist. I see it with Nunit you only have to write a
[Test] before your function and pouf, it's done. But to change from a three line of code to an annotation before the function, you better have the core of your application finish first.
Please, WRITE (you're our developper after all) what you think about this....