I'm restarting the discussion on this because the previous thread [1]
did not reach a conclusion.  I thought it would be useful to summarize
the issues with the extension samples as they stand, and explain how
the patch for TUSCANY-1356 resolves these issues.

In the implementation-crud sample (the client application code), we have
CRUDClient.java, crud.composite, and CRUDTestCase.java.  CRUDClient.java
and crud.composite together provide a sample client that exercises
implementation-crud-extension, and these two files are correctly part
of implementation-crud because they are not part of the extension jar.
The problem with implementation-crud is the inclusion of CRUDTestCase.java,
which does not use or test any of the above client code, but is just a
copy of the same file from implementation-crud-extension (and executed
by mvn when implementation-crud-extension is built).  The patch for
TUSCANY-1356 eliminates this duplicate copy of CRUDTestCase.java in
implementation-crud and adds a new itest (not part of the samples) that
runs the implementation-crud client code to make sure it executes OK.

The crud.composite file from the implementation-crud sample client is also
duplicated as part of the test code for implementation-crud-extension.
There is no need for this code to be duplicated.  The patch for
TUSCANY-1356 eliminates this duplicate copy of crud.composite by having
the JUnit test for implementation-crud-extension use the crud.composite
file that is part of implementation-crud.

Similarly, in the binding-echo-extension sample, under src/test there are
duplicates of the implementation code, composite file, and JUnit test code
from binding-echo.  The patch for TUSCANY-1356 removes duplicate code
from binding-echo-extension by having the JUnit tests in
binding-echo-extension take this code from binding-echo, adds a non-sample
itest to exercise EchoBindingClient.java from binding-echo, and removes
redundant JUnit test code from binding-echo (not needed because the JUnit
tests in binding-echo-extension contains exactly the same code).

With these changes, all duplicate code is eliminated from these samples,
all sample code is tested either by sample JUnit tests or separate
itests, and the distinction between the extension and client/application
samples is much clearer.

  Simon

[1] http://www.mail-archive.com/[email protected]/msg19026.html



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to