You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ol...@apache.org on 2012/04/23 09:45:38 UTC

svn commit: r1329106 [4/6] - in /maven/scm/trunk: ./ maven-scm-client/ maven-scm-client/src/main/resources/META-INF/plexus/ maven-scm-providers/ maven-scm-providers/maven-scm-provider-accurev/src/test/java/org/apache/maven/scm/provider/accurev/command/...

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt Mon Apr 23 07:45:33 2012
@@ -0,0 +1,269 @@
+ --------------
+ Maven SCM Jazz Provider
+ --------------
+ Chris Graham
+ --------------
+ 2012-03-19
+ --------------
+
+ ~~ Licensed to the Apache Software Foundation (ASF) under one
+ ~~ or more contributor license agreements.  See the NOTICE file
+ ~~ distributed with this work for additional information
+ ~~ regarding copyright ownership.  The ASF licenses this file
+ ~~ to you under the Apache License, Version 2.0 (the
+ ~~ "License"); you may not use this file except in compliance
+ ~~ with the License.  You may obtain a copy of the License at
+ ~~
+ ~~   http://www.apache.org/licenses/LICENSE-2.0
+ ~~
+ ~~ Unless required by applicable law or agreed to in writing,
+ ~~ software distributed under the License is distributed on an
+ ~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~~ KIND, either express or implied.  See the License for the
+ ~~ specific language governing permissions and limitations
+ ~~ under the License.
+
+ ~~ NOTE: For help with the syntax of this file, see:
+ ~~ http://maven.apache.org/doxia/references/apt-format.html
+
+ The Jazz provider implements Maven's generic SCM API for the Jazz SCM system.
+
+ Jazz SCM is included in the Rational Team Concert product.
+   
+Use Cases
+
+ The provider must handle a number of different use cases:
+
+ * Label a source tree and check out that label to a temp directory (the release plugin).
+ 
+ * Provide a changelog between dates/revisions and checkout code to a directory (Continuum et al).
+
+ * Map a number of commands designed for CVS/SVN onto the semantics provided by Jazz SCM (the scm plugin).
+
+Details
+
+  The main semantic issue faced by the provider is CVS/SVN's (around which the original SCM API and
+  release manager/plugin where written) concept of a working copy versus Jazz SCM's concept of a Sandbox,
+  Repository Workspace and Stream.
+
+  CVS/SVN allow the user to checkout any repository location to any local directory at will and tracks this
+  by keeping metadata in a CVS/.svn directory. 
+
+Jazz Basics
+
+  Jazz SCM uses a "remote repository workspace", or more commonly called a "repository workspace", which
+  is an object in the repository on the Jazz server, used to store items that have been placed under
+  source control. A "sandbox" is a copy of the "repository workspace" on your local machine, which exists
+  as files and directories, where you perform your changes. The .jazz5 metadata directory contains the
+  metadata for the sandbox, which includes information about which files and folders have been loaded
+  from the remote repository workspace. Overlapping sandboxes (a sandbox within a sandbox) are not permitted.
+  This limitation forces us to use the <<<workingDirectory>>> option when using the <<<release:perform>>>
+  goal. The working directory must be outside of the current sandbox.
+
+Relationships between Streams, Repository Workspaces, Components and Sandboxes.
+
+  In the simplest case, we have a single Repository Workspace, with a single Component in it. Associated with
+  that, we have a sandbox.
+   
+[images/WorkspaceOnly.png] Relationships between Repository Workspaces, Components and Sandboxes.
+
+  Adding a Stream introduces the concept of Flow Targets.
+  
+[images/WorkspaceWithStream.png] Relationships between Streams, Repository Workspaces, Components and Sandboxes.
+
+  A Repository Workspace may be configured to have a Flow Target. A flow target may be a Stream or another
+  Repository Workspace. A Repository Workspace can have multiple flow targets simultaneously. Flow targets
+  can also be changed.
+  
+  A developer will <<<deliver>>> their changes to the flow targets defined for their Repository Workspace.
+  The corresponding action for a Snapshot is the <<<promote>>> operation. Another developer will <<<accept>>>
+  those changes when they are ready too.
+  
+Flow Targets
+
+  V1.4 of the Maven SCM API introduced an option {{{http://maven.apache.org/scm/maven-scm-plugin/checkin-mojo.html#pushChanges}pushChanges}}
+  that allows for changes in distributed SCM to be pushed into a central repository.
+  
+  In Jazz terms, a <<<checkin>>> or <<<load>>> operates between the <<<sandbox>>> and the <<<repository workspace>>>.
+  
+  A <<<deliver>>> or <<<accept>>> operates between a <<<repository workspace>>> and its flow target,
+  normally a <<<stream>>> but could also be another <<<repository workspace>>>. The <<<promote>>> is used to 
+  
+  The Maven <<<pushChanges>>> option controls the <<<deliver>>> or <<<promote>>> operations.
+  
+  The <<<pushChanges>>> option, by default is <<<true>>>, but for the <<<deliver>>> or <<<promote>>> operations
+  to have meaning, the <<<repository workspace>>> needs to have a flow target defined.
+  
+  If the <<<pushChanges>>> option is <<<true>>> (the default), and there is no flow target defined, then no
+  <<<deliver>>> or <<<promote>>> operations are attempted.
+
+Limitations
+
+  One other thing to be aware of, is that Jazz allows you to have the same name for Repository Workspaces,
+  Streams, Components and Baselines. This provider will create a Repository Workspace of the same name as
+  the Snapshot, as currently the underlying tool, <<<scm>>>, does not allow the direct loading of a snapshot
+  into a sandbox. It is recommended that the user implements some namespace standards and policies to help
+  manage this.
+
+URL Format
+
+ <<<scm:jazz:[username[;password]@]http[s]://server_name[:port]/contextRoot:repositoryWorkspace>>>
+ 
+ * <username;password> May be provided directly in the pom, or using the server_name:port to obtain
+ the details from the user's settings.xml file.
+ 
+ * http[s]://server_name:port/contextRoot Specify the jazz server and path to connect to. The context root
+ is usually 'jazz' or 'ccm'.
+     
+ * <repositoryWorkspace> The name of the user's remote repository workspace used to checkin to, or load from.
+
+Working with the Release Plugin
+
+  We are able to use the <<<release:prepare>>> and <<<release:perform>>> goals in the one invocation,
+  however, due to the sandbox within a sandbox issues discussed above, we need to use the <<<workingDirectory>>>
+  option.
+  
+  Here is a sample:
+  
++--
+mvn -B -Dresume=false -DworkingDirectory=/tmp/maven release:prepare release:perform
++--
+
+  For a complete explanation on the restrictions and limitations of using this provider, see
+  the link, "Working with the Release Plugin" above.
+
+SCM Commands
+
+* Login  
+
+ Although the <<<scm>>> command supports persistent login using the <<<scm login>>> command, it is not
+ used by this provider. The username and password can either come from the URL in the pom.xml file, or
+ from a <<< <server> >>> section in a settings.xml file. The password is masked in the output of the
+ execution of the scm command.
+ 
+ <<Note>> Having the username and password set in the pom.xml takes precedence over the <<< <server> >>>
+ entry from settings.xml.
+ 
+* Add
+
+  Jazz SCM does not have the equivalent of an add command. This implementation uses the <<<scm checkin>>>
+  command. However, it does not call the <<<scm deliver>>> command, nor does it create a <<<changeset>>>.
+  
+* Blame
+  
+  This provider uses the <<<scm annotate>>> command.
+  
+* Branch
+
+  Not implemented.
+  
+  A branch in Jazz SCM is roughly equivalent to a Stream or possibly even a Repository Workspace, depending
+  on how the flow targets have been defined, thus the branch command could be used to create a new Stream
+  or Repository Workspace. The Jazz SCM command <<<scm create workspace>>> can be used to create new Repository
+  Workspaces, however, there is currently no <<<scm create stream>>> command.
+
+  Jazz SCM also further complicates the issue by allowing multiple flow targets.
+  
+  This provider does not currently explicitly support multiple flow targets. When there are multiple flow
+  targets defined, the flow target defined as "current" will be used, not the "default" one. This information
+  is obtained from the output of the <<<scm status>>> command.
+  
+  <<<Note>>> Some commands, such as <<<edit>>> and <<<unedit>>> work with the implicit flow targets of the
+  Repository Workspace.   
+
+* Changelog
+
+  This provider uses the <<<scm history>>> command to obtain a list of all changesets. It then uses the
+  <<<scm list changesets>>> to obtain the details of each individual changeset.
+
+* Checkin
+
+  This provider will create a changeset with the provided message.
+  The implementation uses the <<<scm checkin>>> command, it uses the Add command implementation.
+
+  If the repository workspace has a valid flow target (ie, not itself) and the <<<pushChanges>>> option
+  it <<<true>>>, which by default it is, then this provider will also deliver the changes to the
+  flow target using the <<<scm deliver>>> command.
+
+  Note: Only a single flow target is currently supported. When multiple flow targets have been defined,
+  the flow target marked as "current" will be used. This provider is not aware of the other targets. This
+  information is not available from the <<<scm status>>> command. 
+  
+* Checkout
+
+  The implementation uses the <<<scm load>>> command.
+
+* Diff
+
+  The diff implementation produces a diff based on the difference between changes in the sandbox and
+  the repository workspace. A flow target, if defined, is not used. The <<<scm>>> command is not
+  currently able to produce a single diff output of all files that have changed. So the <<<scm status>>>
+  command is used to determine all changed files, and then iterates through the list, calling <<<scm diff>>>
+  for each individual file.
+  
+  By default, an $\{artifactId\}.diff file will be produced in the current working directory. This .diff file
+  can be then imported into the Eclipse Client using the following procedure.
+  
+  Right click, then, Team > Apply Patch... 
+  
+  In the dialog that opened, select the patch file. Note that no files will be shown in the
+  'This patch effects the following files' list. Select Next. Choose the 'Workspace Root'
+  radio button and then click on the Finish button.
+
+  In the 'Pending Changes' view, select 'Merge into Workspace'. The patch will be applied.
+
+* Edit
+
+  The implementation uses the <<<scm lock acquire>>> command, and uses the implicit flow targets defined
+  for the repository workspace. If none are defined, the command will fail.
+  
+* List
+
+  The <<<scm status>>> command is called first to obtain the remote repository workspace and
+  component name. These are then used as parameters for the <<<scm list remotefiles>>> command.
+
+* Status
+
+  This provider uses the <<<scm status>>> command.
+
+* Tag
+
+  The <<<scm status>>> command is called first to obtain the remote repository workspace and
+  stream name. The Jazz SCM equivalent of a tag is a snapshot. A baseline could have been used,
+  however, baselines are not supported or used by this provider. Please note however, that when
+  a snapshot is created, a baseline will also be implicitly created. Also, Jazz SCM currently
+  does not support the loading of a snapshot directly, we can only load from a repository workspace.
+  So, to facilitate this, the tag command also creates a remote workspace repository of the same name
+  as the tag, ie: <<<$\{artifactId\}-$\{version\}>>>.
+
+  This provider can call up to four different <<<scm>>> commands to fully accomplish this function.
+  
+    * The <<<scm create snapshot>>> command is first called to create snapshot.
+    
+    * The <<<scm create workspace>>> command is called to create a repository workspace that can later be loaded by the checkout command (for the release plugin).
+    
+    * The <<<scm deliver>>> command is called to deliver the changes to the flow target (if defined and pushChanges is true).
+    
+    * The <<<scm snapshot promote>>> command is called to promote the snapshot to the flow target (if defined and pushChanges is true). 
+
+* Unedit
+
+  The implementation uses the <<<scm lock release>>> command, and uses the implicit flow targets defined
+  for the repository workspace. If none are defined, the command will fail.
+
+* Update
+
+  This provider uses the <<<scm accept>>> command to receive updates into the remote repository workspace.
+  If a sandbox has been loaded from the remote repository workspace, it too will also be updated. 
+
+Troubleshooting
+ 
+  Generally to get yourself out of trouble you'll need to manipulate Jazz externally by either using the <<<scm>>> command
+  or using the RTC Eclipse client to resolve the issues encountered.
+
+Issues
+
+  The <<<scm>>> command still has a number of issues dealing with files in the sandbox root directory. There are a number of
+  Work Items on jazz.net that have been opened to track this, and other issues raised by the implementation of this provider. 
+  
+  However, despite this, this implemention provides sufficient functionality to be able to successfully work with the maven release plugin.

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/index.apt
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt Mon Apr 23 07:45:33 2012
@@ -0,0 +1,189 @@
+ --------------
+ Maven SCM Jazz Provider - Working with the Release Plugin
+ --------------
+ Chris Graham
+ --------------
+ 2012-03-19
+ --------------
+
+ ~~ Licensed to the Apache Software Foundation (ASF) under one
+ ~~ or more contributor license agreements.  See the NOTICE file
+ ~~ distributed with this work for additional information
+ ~~ regarding copyright ownership.  The ASF licenses this file
+ ~~ to you under the Apache License, Version 2.0 (the
+ ~~ "License"); you may not use this file except in compliance
+ ~~ with the License.  You may obtain a copy of the License at
+ ~~
+ ~~   http://www.apache.org/licenses/LICENSE-2.0
+ ~~
+ ~~ Unless required by applicable law or agreed to in writing,
+ ~~ software distributed under the License is distributed on an
+ ~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~~ KIND, either express or implied.  See the License for the
+ ~~ specific language governing permissions and limitations
+ ~~ under the License.
+
+ ~~ NOTE: For help with the syntax of this file, see:
+ ~~ http://maven.apache.org/doxia/references/apt-format.html
+
+ Using the Release Plugin with the Jazz SCM provider.
+
+Maven Releases
+
+  The normal Maven process of creating a release using the Maven Release Plugin
+  involves a two step process.
+  
+  The first step, <<<mvn release:prepare>>> consists of the following phases:
+
+    * check-poms
+
+    * scm-check-modifications
+    
+    * check-dependency-snapshots
+    
+    * create-backup-poms
+    
+    * map-release-versions
+    
+    * input-variables
+    
+    * map-development-versions
+    
+    * rewrite-poms-for-release
+    
+    * generate-release-poms
+    
+    * run-preparation-goals
+    
+    * scm-commit-release
+    
+    * scm-tag
+    
+    * rewrite-poms-for-development
+    
+    * remove-release-poms
+    
+    * run-completion-goals
+    
+    * scm-commit-development
+    
+    * end-release
+
+    []
+  
+  The tag operation should, as per good SCM practices and Maven best practices,
+  create a tag of just that module, and any sub modules in a multi-module project.
+  
+  The second step, <<<mvn release:perform>>>, consists of the following phases:
+
+    * verify-completed-prepare-phases
+    
+    * checkout-project-from-scm
+    
+    * run-perform-goals
+
+    []
+    
+  The <<<scm create snapshot>>> command, used to implement the Maven SCM Tag command,
+  creates an implicit baseline of *ALL* components within the repository workspace.
+  For this reason, it is *very strongly* recommended that only a single component
+  reside in the repository workspace being used to perform the release.
+
+  A simple suggestion is to use a naming standard of: \<ComponentName\>BuildWorkspace
+  for Repository Workspace names used to perform releases.
+
+  Or, put in a Maven context, tagging multiple projects at the same time,
+  makes absolutely no sense.
+
+  Now, the question becomes, how do we organise our repository workspaces?
+  
+Repository Workspace Organisation
+
+  A suggestion of how a developer can work with Maven, multiple components
+  and multiple developers is shown below.
+     
+[images/FlowDiagram.png] Developer Repository Workspaces, Release Repository Workspaces and Streams.
+
+  The important thing to note, is that a developer can have multiple components,
+  multiple flow targets. They can quite easily use the usual <<<mvn clean install>>>
+  from their Eclipse workspace.
+  
+  They should not, however, attempt to run the release plugin from these environments.
+  
+  It is very strongly recommended that a separate repository workspace, containing just one
+  component, the component to be released, be set up for exactly this purpose.
+  This repository workspace should only have one flow target, which would normally be a stream.
+  Should the repository workspace have multiple flow targets, the flow target marked as "current"
+  will be the one where the changes are flowed to.
+  However, this provider also works perfectly well with a standalone repository workspace, ie,
+  no flow targets.
+
+  This means that the <<<scm>>> settings in the pom must to be configured for the build repository
+  workspace, not the developer's repository workspace. As the developers should not be performing
+  a release, this will not effect them; they will not need to modify the <<<scm>>>
+  section in the pom to point to their specific repository workspace.
+
+  This is what the <<<scm>>> section of the pom.xml file could look like:
+
++--
+    <scm>
+        <url>https://rtc:9444/jazz:GPDBBuildWorkspace</url>
+        <connection>scm:jazz:https://rtc:9444/jazz:GPDBBuildWorkspace</connection>
+        <developerConnection>scm:jazz:https://rtc:9444/jazz:GPDBBuildWorkspace</developerConnection>
+    </scm>
++--
+
+  As the username and password are not in the pom.xml, they must be obtained from the user's <<<settings.xml>>> file.
+  This is a sample of what the <<<server>>> section of the settings.xml file could look like:
+
++--  
+  <servers>
+
+      <server>
+        <id>rtc:9444</id>
+        <username>build</username>
+        <password>build</password>
+      </server>
+
+  </servers>
++--
+
+  In this example, we are using the <<<build>>> user. The GPDBBuildWorkspace would be owned by the <<<build>>> user.
+
+Working with Multiple Streams
+
+  The next step in the normal evolution of a software project would be to start development work on the next release or
+  version of the software. Let's call it Release 2. Ordinarily, you would create a branch to operate in. In Jazz SCM, we
+  create a Stream. 
+  
+  The image below illustrates how this can be achieved: 
+  
+[images/FlowDiagramWithMultipleStreams.png] Developer Repository Workspaces, Release Repository Workspaces with Multiple Streams.
+
+  All of the initial repository workspaces flow into the development stream (all implicitly Release 1). When the new
+  stream for release 2 has been created, the (Release 1) Development Stream is modified so that it has a flow target
+  of the Release 2 Development Stream. The repository workspaces for the Release 2 work are then created and their
+  flow targets flow back to the Release 2 Development Stream.
+  
+  The repository workspaces for the build are again created, and the <<<scm>>> section of the pom.xml file could look like:
+
++--
+    <scm>
+        <url>https://rtc:9444/jazz:GPDBBuildR2Workspace</url>
+        <connection>scm:jazz:https://rtc:9444/jazz:GPDBBuildR2Workspace</connection>
+        <developerConnection>scm:jazz:https://rtc:9444/jazz:GPDBBuildR2Workspace</developerConnection>
+    </scm>
++--
+   
+Working with the Release Plugin
+  
+  We are able to use the <<<release:prepare>>> and <<<release:perform>>> goals in the one invocation,
+  however, due to the sandbox within a sandbox issues discussed, we need to use the <<<workingDirectory>>>
+  option.
+  
+  Here is a sample:
+  
++--
+mvn -B -Dresume=false -DworkingDirectory=/tmp/maven release:prepare release:perform
++--
+  
\ No newline at end of file

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/releases.apt
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt Mon Apr 23 07:45:33 2012
@@ -0,0 +1,113 @@
+ --------------
+ Maven SCM Jazz Provider - TCK Test Implementation Details.
+ --------------
+ Chris Graham
+ --------------
+ 2012-03-19
+ --------------
+
+ ~~ Licensed to the Apache Software Foundation (ASF) under one
+ ~~ or more contributor license agreements.  See the NOTICE file
+ ~~ distributed with this work for additional information
+ ~~ regarding copyright ownership.  The ASF licenses this file
+ ~~ to you under the Apache License, Version 2.0 (the
+ ~~ "License"); you may not use this file except in compliance
+ ~~ with the License.  You may obtain a copy of the License at
+ ~~
+ ~~   http://www.apache.org/licenses/LICENSE-2.0
+ ~~
+ ~~ Unless required by applicable law or agreed to in writing,
+ ~~ software distributed under the License is distributed on an
+ ~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~~ KIND, either express or implied.  See the License for the
+ ~~ specific language governing permissions and limitations
+ ~~ under the License.
+
+ ~~ NOTE: For help with the syntax of this file, see:
+ ~~ http://maven.apache.org/doxia/references/apt-format.html
+
+TCK Tests
+
+  The TCK test the actual implementation of the SCM APIs by calling the provider implementations via JUnit tests. 
+
+Jazz TCK Test Setup
+
+  The Jazz TCK tests are enabled by enabling the <<<tck-jazz>>> profile. This can be done by <<<mvn -Ptck-jazz ...>>>.
+
+  The Jazz TCK tests require three system properties to be defined. These properties can be defined in your local
+  <<<settings.xml>>> file or from the command line, via <<<-D>>>. The latter option may be needed if running the
+  TCK tests as JUnit tests from inside Eclipse.
+
+  * tckBaseDir
+
+    This property must be defined to define where the test snapshot is to be loaded into. Due to the
+    sandbox in a sandbox issue, this must be outside of the existing source tree. This property will
+    still need to be set if Eclipse is being used, and the Eclipse Workspace is a sandbox.
+
+  * tckSnapshotName
+
+    This is the name of an existing snapshot on the Jazz SCM server that is used to load the sandbox
+    used to conduct that TCK tests. This snapshot needs to be created independently of these TCK tests.
+    At the current time, creating a repository workspace with a named component (as opposed to a default
+    one; which causes duplicates when run more than once) is not supported by the Jazz SCM CLI tool.
+    Therefore a snapshot, with the appropriate contents, will need to be created before running these
+    TCK tests, and its name set to the value of the <<<tckSnapshotName>>> property.
+
+  * tckUrl
+
+    This property defines the initial part of the SCM URL that points to the server used to perform the TCK tests against.
+    For example:
+
++---
+  scm:jazz:Deb;Deb@https://rtc:9444/jazz:MavenSCMTCKTestWorkspace
++---
+
+    This is part of the usual SCM URL for Jazz. However, this value is appended with <<<System.currentTimeMillis()>>>
+    as part of the repository workspace name to guarantee uniqueness. A new repostory workspace is created for
+    each TCK test as it is being run.
+    
+  The <<<tckSnapshotName>>> is loaded into the <<<tckBaseDir>>> location from the server referenced in the <<<tckUrl>>>
+  property.
+
+ Jazz creates some challenges for the existing TCK tests.
+ 
+   * Jazz always has an initial baseline. This maps to a revision. SCM's such as SVN/CVS etc, around which
+     the SCM API's and corresponding TCK tests assume that there is no initial revision.
+   
+   * Jazz has no equivalent of a SVN/CVS style <<<add>>> command, whereby you can add a file to a SCM, ie
+     indicate that it is to be added, and not commit it.
+     
+ Fully implemented Jazz TCK tests.
+ 
+   * JazzBlameCommandTckTest
+   
+   * JazzCheckOutCommandTckTest
+ 
+ Functional but failing Jazz TCK tests.
+ 
+   * JazzChangeLogCommandTckTest
+   
+   * JazzCheckInCommandTckTest
+   
+   * JazzDiffCommandTckTest
+   
+   * JazzStatusCommandTckTest
+   
+   * JazzTagCommandTckTest
+   
+   * JazzUpdateCommandTckTest
+   
+   []
+
+   The underlying Jazz SCM CLI tool does have issues with adding or checking in files that are in the sandbox root.
+   Several work items have been opened against the Jazz SCM CLI tool to address these issues.
+   When these work items have been addressed, the Jazz SCM provider should be fully able to support the SCM API and
+   these TCK tests.
+ 
+Cleaning Up
+ 
+   Currently, we can not delete Jazz SCM repository objects using the Jazz SCM CLI tool. A work item has been opened
+   to address this. When this functionality is present, then the removeRepo() method in the TCK tests can be used
+   to perform a cleanup. Until that time, the repository workspaces that are created using these TCK tests will need
+   to be removed using the Eclipse client that has the full functionality to do so.
+   
\ No newline at end of file

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/apt/tcktests.apt
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml Mon Apr 23 07:45:33 2012
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+
+<project name="Maven SCM Jazz Provider">
+  <body>
+    <menu ref="parent" />
+
+    <menu name="Overview">
+      <item name="Introduction" href="index.html"/>
+      <item name="Working with the Release Plugin" href="releases.html"/>
+    </menu>
+
+    <menu ref="reports" inherit="bottom" />
+  </body>
+</project>

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/site/site.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,81 @@
+package org.apache.maven.scm.provider.jazz;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.apache.maven.scm.ScmFileSet;
+import org.apache.maven.scm.ScmTestCase;
+import org.apache.maven.scm.provider.jazz.repository.JazzScmProviderRepository;
+
+/**
+ * The base class for our Jazz test cases.
+ * It sets up a dummy JazzScmProviderRepository for testing purposes.
+ * 
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public abstract class JazzScmTestCase
+    extends ScmTestCase
+{
+
+    /**
+     * Get a dummy JazzScmProviderRepostitory to allow us to test.
+     * @return The dummy JazzScmProviderRepository.
+     */
+    protected JazzScmProviderRepository getScmProviderRepository()
+    {
+        return new JazzScmProviderRepository( "https://localhost:9443/jazz", "myUserName", "myPassword",
+                                              "localhost", 9443, "Dave's Repository Workspace" );
+    }
+
+    /**
+     * Return a list of our files, space separated as a single string.
+     * @return The list of files.
+     */
+    protected String getFiles()
+    {
+        String path = "";
+        for ( Iterator<File> it = getScmFileSet().getFileList().iterator(); it.hasNext(); )
+        {
+            File file = (File) it.next();
+            path += file.getName() + " ";
+        }
+        return path.trim();
+    }
+
+    /**
+     * Return a dummy set of files.
+     * @return A ScmFileSet of dummy files to allow us to test. 
+     */
+    protected ScmFileSet getScmFileSet()
+    {
+        File file1 = new File( "file1" );
+        File file2 = new File( "file2" );
+        List<File> fileList = new ArrayList<File>();
+
+        fileList.add( file1 );
+        fileList.add( file2 );
+
+        return new ScmFileSet( getWorkingDirectory(), fileList );
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/JazzScmTestCase.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,50 @@
+package org.apache.maven.scm.provider.jazz.command;
+
+import org.apache.maven.scm.provider.jazz.JazzScmTestCase;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzScmCommandTest
+    extends JazzScmTestCase
+{
+    public void testFileList()
+    {
+        assertTrue( getScmFileSet().getFileList().size() > 0 );
+    }
+
+    public void testJazzScmCommand()
+    {
+        JazzScmCommand listCommand = new JazzScmCommand( "list", getScmProviderRepository(), null, null );
+        String actual = listCommand.getCommandline().toString();
+        String expected = "cmd.exe /X /C \"scm list --repository-uri https://localhost:9443/jazz --username myUserName --password myPassword\"";
+        assertEquals( "Constructing command line failed!", expected, actual );
+    }
+    
+    public void testCryptPassword()
+    {
+        JazzScmCommand listCommand = new JazzScmCommand( "list", getScmProviderRepository(), null, null );
+        String actual = JazzScmCommand.cryptPassword(listCommand.getCommandline());
+        String expected = "cmd.exe /X /C \"scm list --repository-uri https://localhost:9443/jazz --username myUserName --password *****\"";
+        assertEquals( "cryptPassword failed!", expected, actual );
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzScmCommandTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,242 @@
+package org.apache.maven.scm.provider.jazz.command;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.File;
+
+import org.apache.maven.scm.CommandParameters;
+import org.apache.maven.scm.ScmException;
+import org.apache.maven.scm.ScmFileSet;
+import org.apache.maven.scm.ScmResult;
+import org.apache.maven.scm.command.AbstractCommand;
+import org.apache.maven.scm.log.DefaultLog;
+import org.apache.maven.scm.provider.ScmProviderRepository;
+import org.apache.maven.scm.provider.jazz.command.consumer.DebugLoggerConsumer;
+import org.apache.maven.scm.provider.jazz.command.consumer.ErrorConsumer;
+import org.apache.maven.scm.provider.jazz.repository.JazzScmProviderRepository;
+import org.apache.maven.scm.repository.ScmRepository;
+import org.codehaus.plexus.util.FileUtils;
+import org.codehaus.plexus.util.StringUtils;
+import org.codehaus.plexus.util.cli.StreamConsumer;
+import org.junit.Assert;
+
+/**
+ * Common utilities for Jazz TCK tests.
+ * 
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzTckUtil
+    extends AbstractCommand
+{
+    private long currentSystemTimeMillis = System.currentTimeMillis();
+
+    private String tckBaseDir;
+    
+    private String scmUrl;
+
+    private String snapshotName;
+    
+    /**
+     * Get the specified system property. Borrowed from AccuRevTckUtil.
+     * TODO: Refactor to a common usage.
+     * @param name The name of the property to get.
+     * @param defaultValue A default value if not found.
+     * @return
+     */
+    public String getSystemProperty( String name, String defaultValue )
+    {
+        String mavenProperty = "${" + name + "}";
+        String result = System.getProperty( name, mavenProperty );
+        if ( mavenProperty.equals( result ) )
+        {
+            result = defaultValue;
+        }
+        return result;
+    }
+    
+    /* (non-Javadoc)
+     * @see org.apache.maven.scm.command.AbstractCommand#executeCommand(org.apache.maven.scm.provider.ScmProviderRepository, org.apache.maven.scm.ScmFileSet, org.apache.maven.scm.CommandParameters)
+     */
+    @Override
+    protected ScmResult executeCommand( ScmProviderRepository repository, ScmFileSet fileSet,
+                                        CommandParameters parameters )
+        throws ScmException
+    {
+        JazzScmProviderRepository jazzRepo = (JazzScmProviderRepository) repository;
+
+
+        StreamConsumer tckConsumer = new DebugLoggerConsumer( getLogger() );      // No need for a dedicated consumer for this
+        ErrorConsumer errConsumer = new ErrorConsumer( getLogger() );
+        String nameWorkspace = jazzRepo.getRepositoryWorkspace();
+        //String nameSnapshot = "MavenSCMTestSnapshot";
+        String nameSnapshot = getSnapshotName();
+        JazzScmCommand tckCreateWorkspaceFromSnapshotCmd = createCreateWorkspaceFromSnapshotCommand( jazzRepo, fileSet, nameWorkspace, nameSnapshot );
+        int status = tckCreateWorkspaceFromSnapshotCmd.execute( tckConsumer, errConsumer );
+
+        if ( status != 0 || errConsumer.hasBeenFed() )
+        {
+            return new ScmResult( tckCreateWorkspaceFromSnapshotCmd.getCommandString(),
+                                  "Error code for Jazz SCM (create workspace --snapshot) command - " + status,
+                                  errConsumer.getOutput(), false );
+        }
+        
+        return new ScmResult( tckCreateWorkspaceFromSnapshotCmd.getCommandString(), "All ok", ((DebugLoggerConsumer)tckConsumer).getOutput(), true );
+    }
+
+    // Create the JazzScmCommand to execute the "scm create workspace ..." command
+    // This will create a workspace of the same name as the tag.
+    private JazzScmCommand createCreateWorkspaceFromSnapshotCommand( JazzScmProviderRepository repo, ScmFileSet fileSet, String nameWorkspace, String nameSnapshot)
+    {
+        JazzScmCommand command =
+            new JazzScmCommand( JazzConstants.CMD_CREATE, JazzConstants.CMD_SUB_WORKSPACE, repo, fileSet, getLogger() );
+
+        command.addArgument( nameWorkspace );
+        command.addArgument( JazzConstants.ARG_WORKSPACE_SNAPSHOT );
+        command.addArgument( nameSnapshot );
+
+        return command;
+    }
+
+    /**
+     * If a TCK test case has more than one test case, it will need
+     * to generate a new workspace for each test. Use this method
+     * to provide uniqueness again.
+     */
+    public void generateNewSystemTime()
+    {
+        currentSystemTimeMillis = System.currentTimeMillis();
+    }
+
+    /**
+     * Create a unique repository workspace using the system time, based
+     * upon a supplied snapshot. The creation of this initial snapshot
+     * currently can not be scripted, so it needs to be done manually first.
+     * 
+     * @see org.apache.maven.scm.ScmTckTestCase#initRepo()
+     */
+    public void initRepo( ScmRepository repository )
+        throws Exception
+    {
+        // Set a default logger. because I cann't get to the ones later on...
+        setLogger( new DefaultLog() );
+        // Create the unique workspace based upon a snapshot
+        executeCommand( repository.getProviderRepository(), new ScmFileSet( getWorkingCopy() ), null);
+    }
+
+    /**
+     * This method is available to those SCM clients that need to perform
+     * a cleanup at the end of the tests. It is needed when server side
+     * operations are performed, or the check out dirs are outside
+     * of the normal target directory.
+     */
+    public void removeRepo()
+        throws Exception
+    {
+        FileUtils.deleteDirectory( new File( getTckBaseDir() ) );
+    }
+    
+    /**
+     * Return the URL used for this specific TCK test execution.
+     * It generates a unique workspace name, based on the system time.
+     * 
+     * @see org.apache.maven.scm.ScmTckTestCase#getScmUrl()
+     */
+    public String getScmUrl()
+        throws Exception
+    {
+        if ( scmUrl == null )
+        {
+            // tckUrlPrefix is the system property that is used to seed the SCM URL.
+            // EG:
+            // "scm:jazz:Deb;Deb@https://rtc:9444/jazz:MavenSCMTestWorkspace"
+            //
+            String tckUrlPrefix = getSystemProperty( "tckUrlPrefix", "" );
+            if ( StringUtils.isBlank( tckUrlPrefix ) )
+            {
+                Assert.fail( "Property \"tckUrlPrefix\" is not set." );
+            }
+
+            scmUrl =  tckUrlPrefix + "_" + currentSystemTimeMillis;
+        }
+
+        return scmUrl;
+    }
+
+    /**
+     * Get the snapshot name, getting it from the system properties if necessary.
+     * @return The name of the snapshot used to create a repository workspace,
+     * which is then loaded into the tckBaseDir.
+     */
+    private String getSnapshotName()
+    {
+        if ( snapshotName == null )
+        {
+            snapshotName = getSystemProperty( "tckSnapshotName", "" );
+            if ( StringUtils.isBlank( snapshotName ) )
+            {
+                Assert.fail( "Property \"tckSnapshotName\" is not set." );
+            }
+        }
+
+        return snapshotName;
+    }
+    
+    /**
+     * Get the base directory used for the tck tests.
+     * @return The base directory used for the tck tests, the sandbox.
+     */
+    private String getTckBaseDir()
+    {
+        if ( tckBaseDir == null )
+        {
+            tckBaseDir = getSystemProperty( "tckBaseDir", "" );
+            if ( StringUtils.isBlank( tckBaseDir ) )
+            {
+                Assert.fail( "Property \"tckBaseDir\" is not set." );
+            }
+        }
+
+        return tckBaseDir;
+    }
+    
+    /**
+     * @see org.apache.maven.scm.ScmTestCase#getWorkingCopy()
+     */
+    public File getWorkingCopy()
+    {
+        return new File( getTckBaseDir() + "/wc" );
+    }
+
+    /**
+     * @see org.apache.maven.scm.ScmTestCase#getAssertionCopy()
+     */
+    public File getAssertionCopy()
+    {
+        return new File( getTckBaseDir() + "/ac" );
+    }
+
+    /**
+     * @see org.apache.maven.scm.ScmTestCase#getUpdatingCopy()
+     */
+    public File getUpdatingCopy()
+    {
+        return new File( getTckBaseDir() + "/uc" );
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/JazzTckUtil.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,87 @@
+package org.apache.maven.scm.provider.jazz.command.add;
+
+import org.apache.maven.scm.log.DefaultLog;
+import org.apache.maven.scm.provider.jazz.JazzScmTestCase;
+import org.apache.maven.scm.provider.jazz.repository.JazzScmProviderRepository;
+import org.codehaus.plexus.util.cli.Commandline;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzAddCommandTest
+    extends JazzScmTestCase
+{
+    private JazzScmProviderRepository repo;
+
+    private JazzAddConsumer addConsumer;
+    
+    protected void setUp()
+        throws Exception
+    {
+        super.setUp();
+
+        repo = getScmProviderRepository();
+
+        addConsumer = new JazzAddConsumer( repo, new DefaultLog() );
+    }
+
+    public void testCreateAddCommand()
+        throws Exception
+    {
+        Commandline cmd = new JazzAddCommand().createAddCommand( repo, getScmFileSet() ).getCommandline();
+        String expected = "scm checkin --username myUserName --password myPassword " + getFiles();
+        assertCommandLine( expected, getWorkingDirectory(), cmd );
+    }
+
+    public void testCheckInConsumerWithFiles()
+        throws Exception
+    {
+        addConsumer.consumeLine( "Committing..." );
+        addConsumer.consumeLine( "Workspace: (1903) \"MavenSCMTestWorkspace_1332908068770\" <-> (1903) \"MavenSCMTestWorkspace_1332908068770\"" );
+        addConsumer.consumeLine( "  Component: (1768) \"MavenSCMTestComponent\"" );
+        addConsumer.consumeLine( "    Outgoing:" );
+        addConsumer.consumeLine( "      Change sets:" );
+        addConsumer.consumeLine( "        (1907)  *--@  \"Commit message\"" );
+        addConsumer.consumeLine( "          Changes:" );
+        addConsumer.consumeLine( "            --a-- \\src\\main\\java\\Me.java" );
+        addConsumer.consumeLine( "            --a-- \\src\\main\\java\\Me1.java" );
+        addConsumer.consumeLine( "            --a-- \\src\\main\\java\\Me2.java" );
+    
+        assertEquals( "Wrong number of files parsed!", 3, addConsumer.getFiles().size() );
+        assertEquals( "Parsing error for file1!", "src\\main\\java\\Me.java", addConsumer.getFiles().get( 0 ).getPath() );
+        assertEquals( "Parsing error for file2!", "src\\main\\java\\Me1.java", addConsumer.getFiles().get( 1 ).getPath() );
+        assertEquals( "Parsing error for file3!", "src\\main\\java\\Me2.java", addConsumer.getFiles().get( 2 ).getPath() );
+    }
+
+    public void testCheckInConsumerWithOutFiles()
+        throws Exception
+    {
+        addConsumer.consumeLine( "Committing..." );
+        addConsumer.consumeLine( "Workspace: (1004) \"Release Repository Workspace\" <-> (1005) \"Maven Release Plugin Stream\"" );
+        addConsumer.consumeLine( "  Component: (1006) \"Release Component\"" );
+        addConsumer.consumeLine( "    Outgoing:" );
+        addConsumer.consumeLine( "      Change sets:" );
+        addConsumer.consumeLine( "        (1008) --@ <No comment>" );
+
+        assertEquals( "Wrong number of files parsed!", 0, addConsumer.getFiles().size() );
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/add/JazzAddCommandTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,107 @@
+package org.apache.maven.scm.provider.jazz.command.blame;
+
+import java.io.File;
+import java.util.List;
+
+import org.apache.maven.scm.command.blame.BlameLine;
+import org.apache.maven.scm.command.blame.BlameScmResult;
+import org.apache.maven.scm.provider.jazz.command.JazzTckUtil;
+import org.apache.maven.scm.tck.command.blame.BlameCommandTckTest;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzBlameCommandTckTest
+    extends BlameCommandTckTest
+{
+    // Easy access to our Tck Test Helper class.
+    private JazzTckUtil jazzTckUtil = new JazzTckUtil();
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#initRepo()
+     */
+    @Override
+    public void initRepo()
+        throws Exception
+    {
+        // Create a unique repository workspace for this test.
+        jazzTckUtil.initRepo( getScmRepository() );
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#removeRepo()
+     */
+    @Override
+    public void removeRepo()
+        throws Exception
+    {
+        super.removeRepo();
+        jazzTckUtil.removeRepo();
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#getScmUrl()
+     */
+    @Override
+    public String getScmUrl()
+        throws Exception
+    {
+        return jazzTckUtil.getScmUrl();
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.tck.command.blame.BlameCommandTckTest#verifyResult(org.apache.maven.scm.command.blame.BlameScmResult)
+     */
+    @Override
+    protected void verifyResult( BlameScmResult result )
+    {
+        List<BlameLine> lines = result.getLines();
+        assertEquals( "Expected 1 line in blame!", 1, lines.size() );
+        BlameLine line = lines.get( 0 );
+        assertNotSame( "The revision can not be zero!", "0", line.getRevision() );
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.tck.command.blame.BlameCommandTckTest#isTestDateTime()
+     */
+    @Override
+    protected boolean isTestDateTime()
+    {
+        // The scm annotate command does not return the time, only the date, so we turn the comparison off
+        return false;
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTestCase#getWorkingCopy()
+     */
+    @Override
+    protected File getWorkingCopy()
+    {
+        return jazzTckUtil.getWorkingCopy();
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTckTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,76 @@
+package org.apache.maven.scm.provider.jazz.command.blame;
+
+import java.util.Locale;
+
+import org.apache.maven.scm.log.DefaultLog;
+import org.apache.maven.scm.provider.jazz.JazzScmTestCase;
+import org.apache.maven.scm.provider.jazz.repository.JazzScmProviderRepository;
+import org.codehaus.plexus.util.cli.Commandline;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzBlameCommandTest
+    extends JazzScmTestCase
+{
+    private JazzScmProviderRepository repo;
+    
+    private JazzBlameConsumer blameConsumer;
+
+    private Locale defaultLocale;
+
+    protected void setUp()
+        throws Exception
+    {
+        super.setUp();
+        repo = getScmProviderRepository();
+        blameConsumer = new JazzBlameConsumer( repo, new DefaultLog() );
+        defaultLocale = Locale.getDefault();
+    }
+
+    protected void tearDown()
+        throws Exception
+    {
+        Locale.setDefault( defaultLocale );
+    }
+
+    public void testCreateBlameCommand()
+        throws Exception
+    {
+        Commandline cmd = new JazzBlameCommand().createBlameCommand( repo, getScmFileSet(), "test.txt").getCommandline();
+        String expected = "scm annotate --username myUserName --password myPassword test.txt";
+        assertCommandLine( expected, getWorkingDirectory(), cmd );
+    }
+
+    public void testConsumer()
+    {
+//      C:\tmp\maven\BogusTest>scm annotate --username Deb --password Deb test.txt
+//      1 Deb (1008) 2011-12-14                       Test.txt
+//      2 Deb (1005) 2011-12-14 59 My commit comment.
+        
+        blameConsumer.consumeLine( "1 Deb (1008) 2011-12-14                       Test.txt" );
+        blameConsumer.consumeLine( "2 Deb (1005) 2011-12-14 59 My commit comment." );
+
+        assertEquals( "Wrong number of lines parsed!", 2, blameConsumer.getLines().size() );
+    }
+
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/blame/JazzBlameCommandTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,36 @@
+package org.apache.maven.scm.provider.jazz.command.branch;
+
+import org.apache.maven.scm.provider.jazz.JazzScmTestCase;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * The branch command is not implemented, so neither is this.
+ * 
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzBranchCommandTest
+    extends JazzScmTestCase
+{
+    public void testCommandline()
+    {
+        // TODO
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/branch/JazzBranchCommandTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java?rev=1329106&view=auto
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java (added)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java Mon Apr 23 07:45:33 2012
@@ -0,0 +1,80 @@
+package org.apache.maven.scm.provider.jazz.command.changelog;
+
+import java.io.File;
+
+import org.apache.maven.scm.provider.jazz.command.JazzTckUtil;
+import org.apache.maven.scm.tck.command.changelog.ChangeLogCommandTckTest;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ * @author <a href="mailto:ChrisGWarp@gmail.com">Chris Graham</a>
+ */
+public class JazzChangeLogCommandTckTest
+    extends ChangeLogCommandTckTest
+{
+    // Easy access to our Tck Test Helper class.
+    private JazzTckUtil jazzTckUtil = new JazzTckUtil();
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#initRepo()
+     */
+    @Override
+    public void initRepo()
+        throws Exception
+    {
+        // Create a unique repository workspace for this test.
+        jazzTckUtil.initRepo( getScmRepository() );
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#removeRepo()
+     */
+    @Override
+    public void removeRepo()
+        throws Exception
+    {
+        super.removeRepo();
+        jazzTckUtil.removeRepo();
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTckTestCase#getScmUrl()
+     */
+    @Override
+    public String getScmUrl()
+        throws Exception
+    {
+        return jazzTckUtil.getScmUrl();
+    }
+
+    /**
+     * {@inheritDoc}
+     * @see org.apache.maven.scm.ScmTestCase#getWorkingCopy()
+     */
+    @Override
+    protected File getWorkingCopy()
+    {
+        return jazzTckUtil.getWorkingCopy();
+    }
+}

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/scm/trunk/maven-scm-providers/maven-scm-provider-jazz/src/test/java/org/apache/maven/scm/provider/jazz/command/changelog/JazzChangeLogCommandTckTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision