Skip to Content.
Sympa Menu

notify-dpml - r1453 - in trunk/main: . central/src/docs/depot/tasks depot/library/etc depot/tools/builder/src/main/net/dpml/tools/impl depot/tools/builder/src/main/net/dpml/tools/model depot/tools/builder/src/main/net/dpml/tools/tasks metro/job/impl/etc metro/runtime/etc metro/state/impl/etc metro/test/etc planet/http/impl/etc planet/process/info/etc station/api/etc transit/core/etc util/cli/etc

notify-dpml AT lists.ibiblio.org

Subject: DPML Notify

List archive

Chronological Thread  
  • From: mcconnell at BerliOS <mcconnell AT mail.berlios.de>
  • To: notify-dpml AT lists.ibiblio.org
  • Subject: r1453 - in trunk/main: . central/src/docs/depot/tasks depot/library/etc depot/tools/builder/src/main/net/dpml/tools/impl depot/tools/builder/src/main/net/dpml/tools/model depot/tools/builder/src/main/net/dpml/tools/tasks metro/job/impl/etc metro/runtime/etc metro/state/impl/etc metro/test/etc planet/http/impl/etc planet/process/info/etc station/api/etc transit/core/etc util/cli/etc
  • Date: Tue, 23 May 2006 07:33:44 +0200

Author: mcconnell
Date: 2006-05-23 07:33:36 +0200 (Tue, 23 May 2006)
New Revision: 1453

Added:
trunk/main/depot/library/etc/resources/
trunk/main/metro/job/impl/etc/resources/
trunk/main/metro/runtime/etc/resources/
trunk/main/metro/state/impl/etc/resources/
trunk/main/metro/test/etc/resources/
trunk/main/planet/http/impl/etc/resources/
trunk/main/planet/process/info/etc/resources/
trunk/main/station/api/etc/resources/
trunk/main/transit/core/etc/resources/
trunk/main/util/cli/etc/resources/
Removed:
trunk/main/depot/library/etc/test/
trunk/main/metro/job/impl/etc/test/
trunk/main/metro/runtime/etc/test/
trunk/main/metro/state/impl/etc/test/
trunk/main/metro/test/etc/test/
trunk/main/planet/http/impl/etc/test/
trunk/main/planet/process/info/etc/test/
trunk/main/station/api/etc/test/
trunk/main/transit/core/etc/test/
trunk/main/util/cli/etc/test/
Modified:
trunk/main/bootstrap.xml
trunk/main/central/src/docs/depot/tasks/prepare.xml

trunk/main/depot/tools/builder/src/main/net/dpml/tools/impl/DefaultContext.java
trunk/main/depot/tools/builder/src/main/net/dpml/tools/model/Context.java

trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/PrepareTask.java
Log:
update layout to handle separation of resources used in tests as distinct
from resources added to taget/build/test

Modified: trunk/main/bootstrap.xml
===================================================================
--- trunk/main/bootstrap.xml 2006-05-22 17:59:49 UTC (rev 1452)
+++ trunk/main/bootstrap.xml 2006-05-23 05:33:36 UTC (rev 1453)
@@ -156,6 +156,7 @@
<property name="etc.main" value="${etc}/main"/>
<property name="etc.deliverables" value="${etc}/deliverables"/>
<property name="etc.test" value="${etc}/test"/>
+ <property name="etc.resources" value="${etc}/resources"/>

<property name="target" value="target"/>
<property name="target.dir" location="${basedir}/${target}"/>
@@ -238,18 +239,38 @@
<available file="${etc.test}" property="etc.test.available"/>
<target name="prepare-etc-test" if="etc.test.available">
<!--
- Any files in etc/test get copied over to target/test with filtering
+ Any files in etc/test get copied over to target/build/test with filtering
applied.
-->
+ <mkdir dir="${target.build.test.dir}"/>
+ <copy toDir="${target.build.test.dir}" filtering="on"
failonerror="false">
+ <fileset dir="${etc.test}">
+ <include name="**/*"/>
+ <exclude name="**/*.jar"/>
+ </fileset>
+ </copy>
+ <copy toDir="${target.build.test.dir}" filtering="off"
failonerror="false">
+ <fileset dir="${etc.test}">
+ <include name="**/*.jar"/>
+ </fileset>
+ </copy>
+ </target>
+
+ <available file="${etc.resources}" property="etc.resources.available"/>
+ <target name="prepare-etc-resources" if="etc.resources.available">
+ <!--
+ Any files in etc/resources get copied over to target/test with filtering
+ applied.
+ -->
<mkdir dir="${target.test.dir}"/>
<copy toDir="${target.test.dir}" filtering="on" failonerror="false">
- <fileset dir="${etc.test}">
+ <fileset dir="${etc.resources}">
<include name="**/*"/>
<exclude name="**/*.jar"/>
</fileset>
</copy>
<copy toDir="${target.test.dir}" filtering="off" failonerror="false">
- <fileset dir="${etc.test}">
+ <fileset dir="${etc.resources}">
<include name="**/*.jar"/>
</fileset>
</copy>
@@ -266,6 +287,7 @@
<exclude name="${etc.main}/*"/>
<exclude name="${etc.test}/*"/>
<exclude name="${etc.deliverables}/*"/>
+ <exclude name="${etc.resources}/*"/>
</fileset>
</copy>
</target>
@@ -349,7 +371,7 @@
</target>

<target name="prepare"
depends="init,prepare-etc-deliverable,prepare-etc-main,
- prepare-etc-test,prepare-etc, prepare-src-main, prepare-src-test,
+ prepare-etc-test,prepare-etc-resources,prepare-etc, prepare-src-main,
prepare-src-test,
prepare-build-main, prepare-build-test">
<tstamp/>
</target>

Modified: trunk/main/central/src/docs/depot/tasks/prepare.xml
===================================================================
--- trunk/main/central/src/docs/depot/tasks/prepare.xml 2006-05-22 17:59:49
UTC (rev 1452)
+++ trunk/main/central/src/docs/depot/tasks/prepare.xml 2006-05-23 05:33:36
UTC (rev 1453)
@@ -44,6 +44,7 @@
/main -- resource to be copied to target/build/main
/test -- resource to be copied to target/build/test
/docs -- resource to be copied to target/build/docs
+ /resources -- resource to be copied to target/test
/** -- copied to target/**

</source>
@@ -60,6 +61,8 @@
/deliverables -- output artifacts initially populated with
the content from /target/etc/deliverables
if present
+ /test -- working test directory initially populated
+ with the content from ${project.etc}/resources
</source>



Copied: trunk/main/depot/library/etc/resources (from rev 1452,
trunk/main/depot/library/etc/test)

Modified:
trunk/main/depot/tools/builder/src/main/net/dpml/tools/impl/DefaultContext.java
===================================================================
---
trunk/main/depot/tools/builder/src/main/net/dpml/tools/impl/DefaultContext.java
2006-05-22 17:59:49 UTC (rev 1452)
+++
trunk/main/depot/tools/builder/src/main/net/dpml/tools/impl/DefaultContext.java
2006-05-23 05:33:36 UTC (rev 1453)
@@ -143,6 +143,7 @@
project.setNewProperty( "project.etc.dir",
getEtcDirectory().toString() );
project.setNewProperty( "project.etc.main.dir",
getEtcMainDirectory().toString() );
project.setNewProperty( "project.etc.test.dir",
getEtcTestDirectory().toString() );
+ project.setNewProperty( "project.etc.resources.dir",
getEtcResourcesDirectory().toString() );

project.setNewProperty( "project.target.dir",
getTargetDirectory().toString() );
project.setNewProperty( "project.target.build.main.dir",
getTargetBuildMainDirectory().toString() );
@@ -394,6 +395,16 @@
}

/**
+ * Return the project etc/resources directory.
+ * @return the directory
+ */
+ public File getEtcResourcesDirectory()
+ {
+ String path = getProperty( "project.etc.resources", "etc/resources"
);
+ return createFile( path );
+ }
+
+ /**
* Return the project target directory.
* @return the directory
*/

Modified:
trunk/main/depot/tools/builder/src/main/net/dpml/tools/model/Context.java
===================================================================
--- trunk/main/depot/tools/builder/src/main/net/dpml/tools/model/Context.java
2006-05-22 17:59:49 UTC (rev 1452)
+++ trunk/main/depot/tools/builder/src/main/net/dpml/tools/model/Context.java
2006-05-23 05:33:36 UTC (rev 1453)
@@ -135,6 +135,12 @@
File getEtcTestDirectory();

/**
+ * Return the project etc/resources directory.
+ * @return the directory
+ */
+ File getEtcResourcesDirectory();
+
+ /**
* Return the project target directory.
* @return the directory
*/

Modified:
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/PrepareTask.java
===================================================================
---
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/PrepareTask.java
2006-05-22 17:59:49 UTC (rev 1452)
+++
trunk/main/depot/tools/builder/src/main/net/dpml/tools/tasks/PrepareTask.java
2006-05-23 05:33:36 UTC (rev 1453)
@@ -161,11 +161,29 @@
//

final File etcTest = context.getEtcTestDirectory();
- final File test = context.getTargetDirectory( "test" );
+ //final File test = context.getTargetDirectory( "test" );
+ final File test = context.getTargetDirectory( "build/test" );
copy( etcTest, test, true, includes, excludes );
copy( etcTest, test, false, excludes, "" );
}

+ if( context.getEtcResourcesDirectory().exists() )
+ {
+ final String includes =
+ context.getProperty( ETC_FILTERED_INCLUDES_KEY,
ETC_FILTERED_INCLUDES_VALUE );
+ final String excludes =
+ context.getProperty( ETC_FILTERED_EXCLUDES_KEY,
ETC_FILTERED_EXCLUDES_VALUE );
+
+ //
+ // copy ${etc}/test content to ${target}/build/test
+ //
+
+ final File etcResources = context.getEtcResourcesDirectory();
+ final File test = context.getTargetDirectory( "test" );
+ copy( etcResources, test, true, includes, excludes );
+ copy( etcResources, test, false, excludes, "" );
+ }
+
if( context.getEtcDirectory().exists() )
{
final String includes =
@@ -181,8 +199,9 @@

String main = context.getEtcMainDirectory().toString() + "/**";
String test = context.getEtcTestDirectory().toString() + "/**";
+ String resources = context.getEtcResourcesDirectory().toString()
+ "/**";
File target = context.getTargetDirectory();
- final String standard = main + "," + test;
+ final String standard = main + "," + test + "," + resources;
copy( etc, target, true, includes, standard + "," + excludes );
copy( etc, target, false, excludes, standard );
}

Copied: trunk/main/metro/job/impl/etc/resources (from rev 1452,
trunk/main/metro/job/impl/etc/test)

Copied: trunk/main/metro/runtime/etc/resources (from rev 1452,
trunk/main/metro/runtime/etc/test)

Copied: trunk/main/metro/state/impl/etc/resources (from rev 1452,
trunk/main/metro/state/impl/etc/test)

Copied: trunk/main/metro/test/etc/resources (from rev 1452,
trunk/main/metro/test/etc/test)

Copied: trunk/main/planet/http/impl/etc/resources (from rev 1452,
trunk/main/planet/http/impl/etc/test)

Copied: trunk/main/planet/process/info/etc/resources (from rev 1452,
trunk/main/planet/process/info/etc/test)

Copied: trunk/main/station/api/etc/resources (from rev 1452,
trunk/main/station/api/etc/test)

Copied: trunk/main/transit/core/etc/resources (from rev 1452,
trunk/main/transit/core/etc/test)

Copied: trunk/main/util/cli/etc/resources (from rev 1452,
trunk/main/util/cli/etc/test)




  • r1453 - in trunk/main: . central/src/docs/depot/tasks depot/library/etc depot/tools/builder/src/main/net/dpml/tools/impl depot/tools/builder/src/main/net/dpml/tools/model depot/tools/builder/src/main/net/dpml/tools/tasks metro/job/impl/etc metro/runtime/etc metro/state/impl/etc metro/test/etc planet/http/impl/etc planet/process/info/etc station/api/etc transit/core/etc util/cli/etc, mcconnell at BerliOS, 05/23/2006

Archive powered by MHonArc 2.6.24.

Top of Page