Report on Unit Testing MVP Presenters. 
Author Message
 Report on Unit Testing MVP Presenters.

I posted on this subject a couple of weeks ago, and I ended up
referring to William Wake's Xplorations site for references. Since I
might as well follow my own advice I ended up doing a Dolphin version
of the two Unit Testing tutorials that Wake has written (one for the
model, the other for the GUI), in order to familiarize myself with
Dolphin.

I found that while trying to remain as close to the spirit of Wake's
code as possible (Wake's tutorials are implemented with Java Swing),
almost none of the tests actually needed to instantiate the View
objects at all. This gave a warm fuzzy feeling on the MVP concept of
splitting the UI into presenters and views. I think that it's pretty
cool that most of the tests that require you to instantiate actual GUI
objects in Swing, only requires the Presenters and sometimes the
Model(s) for similar tests in Dolphin. My preliminary conclusion is
that Unit Testing Presenter classes is definitely doable and seems to
be worthwhile for those who like to work test that way.

If anyone is interested in the Package containing the test and
application classes for the Dolphin port of the Wake tutorial, please
say so. It would be interesting if anyone could criticize it too.

I've always been somewhat disgusted by the GUI frameworks in other
languages I've programmed in (MFC, Tkinter(Python), wxPython, VB). I've
always felt that they've lumped things together in an unpleasant way,
but Dolphin has another feel to it. I think I am getting hooked here :-)

To repeat what I've stated in the previous post on this subject:
Wake's Original Java version is located at:
http://www.*-*-*.com/
(The articles are The Test/Code cycle in XP: Part 1/2)

The two articles above are also available in print:
(Part 1)
Extreme Programming Explored by W. Wake.
        Chapter 1. How Do you write a program.

(Part 2)
Extreme Programming Installed by Ron Jeffries et al.
        Chapter 31. A Java Perspective by W. Wake

--

Vennlig hilsen

Syver Enstad



Tue, 17 Aug 2004 22:24:16 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Newbie: Unit testing presenters?

2. Test::Unit::Mock: Mock objects for testing with Test::Unit

3. MVP: Presenter vs. View

4. MVP Presenter skeleton code generator (view driven) released...

5. using test::unit for C++ unit tests

6. Test::Unit 0.1.8 reporting problem

7. Test order in Test::Unit

8. Test order in Test::Unit

9. Automating UI tests (was Re: Art of Unit Testing)

10. Unit testing data; What to test

11. Test Tool for Unit Tests?

12. tcl-7.0 on aix 3.2.4, make test reports error in format.test

 

 
Powered by phpBB® Forum Software