[EMAIL PROTECTED] wrote:
> 
> On Mon, 28 Aug 2000, burtonator wrote:
> > In Jetspeed... I have implemented a Test framework... very very basic..
> > Just uses ant to call out to tasks and if they throw an exception, then
> > the test failed.
> 
> Just FYI there is now a unit testing framework in Avalon src

OK... didn't see this.  Will check it out.  The test framework is so
simple it was worth it :)

> > The problem is that internally Jetspeed could log an error (NPE, etc)
> > and the Test might think that everything worked fine.  The *perfect*
> > place to catch this is the Turbine Log.
> >
> > What I propose is to add a LogListerner interface.  IE:
> 
> well actually there is also a logging framework in Avalon at
> this time. Instead of adding log listeners you can do the
> equivelent by setting the default LogTarget. The LogTarget
> gets handed log messages - one of the fields holds the log
> level and thus you could work it via that.

Can you set multiple targets?  It would be good to make the Turbine
logging mechanism Avalon aware... need to catch up here.  Avalon is
starting to get more (well deserved) attention.
 
> > This way anyone could fork off any log operation, detection, (or
> > correction mechanism) they wanted.  This could also allow us to add
> > additional functionality.  IE we could have multiple default listeners.
> > IE FileSystemLoggerListener (log the the FS), DatabaseLoggerListener
> > (log to a DB), ConsoleLoggerListener (log the the console),
> > SNMPLoggerListener(log to SNMP) (granted some of this stuff can be done
> > with log4j).  My implementation would just cause Ant to terminate with a
> > build failure by throwing a RuntimeException the second that error() is
> > called.
> 
> well currently the logger implementation in Avalon allows
> filtering but can only write to files. This is because my
> other implementations (Mail, IRC channel, stdout) are owned
> by companies - as soon as I remember to get them to OK an OS
> release I will add them :P
> 
> > Granted I won't have time to do *all* of this and it might take me until
> > I get Jetspeed (more)stable to do any impl but IMO it is a good idea and
> > a solid direction towards the future.
> 
> UnitTesting is a godsend :P and loggin is also a champ - I
> wish more OS projects encouraged it :P
<snip>

Yes... I want to start requireing more UnitTesting with Jetspeed.  My
opinion is that it isn't hard... people usually write test code in
development mode anyway.

Kevin

-- 
** Should SUN Open Source Java? Please Vote: 
http://relativity.yi.org/java **

Kevin A Burton (e-mail: [EMAIL PROTECTED], UIN: 73488596, ZKey:
burtonator)
http://relativity.yi.org
Message to SUN Microsystems:  "Please Open Source Java!"
To fight and conquer in all your battles is not supreme excellence;
supreme 
excellence consists in breaking the enemy's resistance without fighting.
    - Sun Tzu, 300 B.C.


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to