Hi Chad,

thanks for the description of your strategy. Basically it is OK but I'd
like to add one architectural constraint:

Could you design it in a way so that andromda-core does not become
dependent on cartridges or samples? Core scripts should not call scripts
from other modules, it should be the other way round: cartridges and
samples should call (depend on) the core.

Is it possible to design it that way, maybe by introducing another
module if necessary?

Cheers...
Matthiass

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf 
> Of Chad Brandon
> Sent: Tuesday, July 29, 2003 9:38 PM
> To: Matthias Bohlen; [EMAIL PROTECTED]
> Subject: RE: [Andromda-devel] test target int core build.xml
> 
> 
> Ok in short, here are some rough steps of what I've
> been thinking when it comes to the regression test:
> 
> Since we have the samples module (the
> car-rental-system) which generates from every
> template, I was thinking that we could call and build
> the car-rental-system from the samples and cartridges
> modules and run the test against the generated build
> output from the car-rental-system.  This way we don't
> need to maintain an extra model file as well as
> another build file that does the exact same thing that
> the samples build file already does for us.
> 
> Here is rougly how the process would go:
> 
> 1) Call the test-regression target from the core's
> build.xml --> ant test-regression
> 
> 2) This target calls other target(s) which compile
> AndroMDA and its test source files.
> 
> 3)A call to a target which builds both the cartridges
> module as well as the car-rental-system is made.  The
> car-rental-system generated XML and JAVA files are
> then copied to our "generated" compare directory which
> exists within the core's build directory
> 
> 4)A check is made by ANT to determine if the
> regression test "drafts" directory exists within the
> core's build directory.  This has two possible
> outcomes:
> 
>     a) if the directory does exist, then we already
> have our "drafts" from which to compare the files  and
> we continue to step 5.
> 
>     b)If the directory does NOT exist then we creates
> this directory and copy over the same generated files
> from step 3 to our "drafts" directory. 
> 
> 5) The test-regression body is now executed and
> another "junit" task is run that executes the
> org.andromda.cartridges.regression.RegressionTest
> which runs both the
> org.andromda.cartridges.regression.JavaSourceComparator
> and org.andromda.cartridges.regression.XmlComparator
> to compare the "drafts" directory contents with the
> "generated" directory contents and generates a Junit
> test report in the build/test/reports directory
> 
> 6)Now make a change to a cartridge template, and
> re-run the "test-regression" target and go look at the
> generated Junit test report
> (TEST-org.andromda.cartridges.regression.RegressionTest.txt)
> to see if any of the API tests failed (meaning the
> changes you made caused differences in the generated
> API)
> 
> As you can see you'll need to run the regression-test
> twice for it to be useful (once to generate the
> initial "drafts" and other time to compare the
> generated files for any change you've made to a
> cartridge template).  
> 
> What do you think?
> 
> Chad
> 
> --- Matthias Bohlen <[EMAIL PROTECTED]> wrote:
> > Hi Chad,
> > 
> > on my machine, JUnit runs but one or two tests fail.
> > I did not have the
> > time to look at them, however.
> > 
> > > I'm in the process of adding the regression 
> > > CodeUnit tests as a sub target to the to the
> > "test" target 
> > 
> > Could you first describe how the core and the
> > cartridges will work
> > together to achieve a regression test? Where do you
> > put the reference
> > API files (the test fixture in terms of JUnit)? In
> > the core or in the
> > cartridges? For example: does the EJB cartridge get
> > its own set of
> > reference files?
> > 
> > Cheers...
> > Matthias
> > 
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED] 
> > >
> > [mailto:[EMAIL PROTECTED]
> > On Behalf 
> > > Of Chad Brandon
> > > Sent: Tuesday, July 29, 2003 1:02 AM
> > > To: [EMAIL PROTECTED]
> > > Subject: [Andromda-devel] test target int core
> > build.xml
> > > 
> > > 
> > > Quick question about the core build.xml "test"
> > target:
> > > 
> > > Is the "test" target in andromda-all core
> > build.xml currently 
> > > working?  I'm in the process of adding the
> > regression 
> > > CodeUnit tests as a sub target to the to the
> > "test" target 
> > > but it fails on the junit task when running
> > without any 
> > > changes.  Before I spend time fixing it, I wanted
> > to make 
> > > sure that its
> > > not my environment thats broken.   I keep on
> > getting the ant 
> > > message that it
> > > couldn't find the task or a class that the junit
> > task relies 
> > > upon.  I just checked out the andromda-all module
> > so I'm not 
> > > sure what could be configured wrong since the
> > class paths are 
> > > all set up by the build file.
> > > 
> > > Thanks,
> > > 
> > > Chad
> > > 
> > > 
> > > 
> > > 
> > >
> >
> -------------------------------------------------------
> > > This SF.Net email sponsored by: Free pre-built
> > ASP.NET sites 
> > > including Data Reports, E-commerce, Portals, and
> > Forums are 
> > > available now. Download today and enter to win an
> > XBOX or 
> > > Visual Studio .NET. 
> > >
> >
> http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet
> > _072303_01/01
> > _______________________________________________
> > Andromda-devel mailing list
> > [EMAIL PROTECTED]
> >
> https://lists.sourceforge.net/lists/listinfo/andromda-devel
> > 
> > 
> 
> 
> 
> 
> -------------------------------------------------------
> This SF.Net email sponsored by: Free pre-built ASP.NET sites including
> Data Reports, E-commerce, Portals, and Forums are available now.
> Download today and enter to win an XBOX or Visual Studio .NET.
> http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet
> _072303_01/01
> _______________________________________________
> Andromda-devel mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/andromda-devel
> 




-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
_______________________________________________
Andromda-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/andromda-devel

Reply via email to