Developing adaptors
Testing adaptors
mvn install:install-file -DgroupId=org.apache.maven.archetypes \ -DartifactId=maven-archetype-jsaga -Dversion=1.0 -Dpackaging=jar \ -Dfile=maven-archetype-jsaga-1.0.jar
mvn archetype:generate -DarchetypeArtifactId=maven-archetype-jsaga
mvn test
diff -Naur -xbuild <origin> <modified>
log4j.rootLogger=DEBUG, A1 log4j.logger.org.apache.axis.transport.http.HTTPSender=DEBUG log4j.appender.A1=org.apache.log4j.FileAppender log4j.appender.A1.File=/tmp/ws.log log4j.appender.A1.layout=org.apache.log4j.PatternLayout log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x %m%n
etc/log4j.properties
# initialization git clone git://git.in2p3.fr/jsaga cd jsaga git remote add jsaga-contrib ssh://git.in2p3.fr/jsaga-contrib # list existing branches git ls-remote ssh://git.in2p3.fr/jsaga-contrib # create your own branch git checkout -b myBranch # modify your code ... # commit your modifications git commit ... # push your commits to your remote branch in the jsaga-contrib repository git push jsaga-contrib HEAD:myBranch
mvn install mvn -s profiles.xml eclipse:eclipse
Most adaptors allow for listing available tests:
ls test/src/integration/ mvn integration-test -Dtest={integration.MyProtocolIntegrationTestSuite}\$index
To run {SubTest1} only, enter:
mvn integration-test -Dtest={integration.MyProtocolIntegrationTestSuite\$SubTest1}
Errors are logged into build/surefire-reports/{integration.MyProtocolIntegrationTestSuite$SubTest1}.txt
Note: On Unix-like operating systems, the '$' must be escaped ('\$').
To run {MyProtocolIntegrationTestSuite}, enter:
junit-run-test {integration.MyProtocolIntegrationTestSuite}
Errors are displayed on console.
# can be empty
myprotocol.base.url=uri://... myprotocol.base2.url=uri://... test.base.url=test://emulator.test.org:1234/
myprotocol.jobservice.url=uri://... # optional test parameters: myprotocol.finalyTimeout=... myprotocol.maxQueuingTime=... myprotocol.candidate.host=...
mkdir -p dir/subdir ; echo "Content of file 1..." > dir/subdir/file1.txt mkdir -p dir2/subdir ; echo "Content of file 2 on base2.url..." > dir2/subdir/file2.txt