Blog  |  Contact Us

Search the Knowledgebase Browse by Category
TestTrack Perforce Integration
Last Updated
18th of July, 2011

TestTrack supports integration with Perforce SCM. See TestTrack SCC and IDE Integrations for supported platforms and versions.

This article includes information about the integration requirements, setting up the integration, performing Perforce actions in TestTrack, and troubleshooting.

Note: The following steps were tested using TestTrack 2011.1.2 and Perforce 2010.2.

 

Windows requirements

The Perforce client must be installed and able to connect to the Perforce server. The same connection used by the Perforce client is used when setting up the connection information in TestTrack.

Perforce must also be set as an SCC provider in the registry. This registry key points to the directory where the Perforce SCCI.DLL file is installed.

Setting up the integration

  1. In the TestTrack Client, choose Tools > SCC Integration. The Configure SCC Integration dialog box opens with the Local Options category selected.

    pflocaloptions2.png
  2. Select Perforce SCM in the Available Providers list and click Make Current.
  3. Select the User Options category.

    pfuseroptions2.png
  4. Enter the Perforce server and port number in the the Server:Port field. For example, Server1:1666.
  5. Enter the Perforce workspace name without the path in the Workspace field. For example, if the workspace is located in C:\Documents and Settings\User\Perforce\p4server_1666\my_workspace, enter my_workspace.
  6. Enter the Perforce Username and Password and click Validate Connection. TestTrack validates the connection to Perforce. If errors occur, review the information entered.
  7. Select the Project Options category to set the Perforce File Attach options.
    • Select Retrieve all files at once if you are connecting to a small-to-medium Perforce server. Selecting this option improves overall performance because TestTrack only makes one call to build the file listing for the Perforce tree.
    • Select Retrieve files by directory if you are connecting to a large Perforce server. Selecting this option improves performance because TestTrack retrieves file listings for Perforce folders as you select them instead of retrieving the entire tree at once.
  8. Select the Project Paths category.

    pfprojectpaths2.png
  9. Expand the Branch tree and select a depot. Users can access all files in the Perforce database if you select the root depot. Select specific depots to limit files users can access.
  10. Click Add.
  11. Click OK. Perforce is now integrated with TestTrack.

Performing Perforce actions in TestTrack

You can access the following Perforce commands on the Source Code tab when editing TestTrack items: Attach, Detach, Sync, Open for Edit, Revert, Submit, View, and History.

Attach File
Attaches source code files to TestTrack items. You may notice a small performance delay depending on the number of attached files in the project. This delay is not caused by the total number of files in Perforce.
  1. Click the Source Code tab and click Attach File. The Attach Files dialog box opens.

    pfattachfiles2.png
  2. Select the files you want to attach to the item and click Add.
  3. Click OK. The source code files are attached.
  4. Click OK in the Edit window to save the changes.
Detach
Removes attached source code files.
  1. Select the file you want to detach on the Source Code tab and click Detach. You are prompted to confirm the action.
  2. Click Yes to confirm the detach. The file is no longer attached to the item.
Sync
Retrieves a read-only copy of the latest version of the file. Checked out or locked files are not retrieved.
  1. Select the file you want to retrieve and click Sync. The Get Files dialog box opens.

    Note:
    The Browse button is disabled because the Sync operation only retrieves files to the workspace.
  2. Click OK. The latest version of the file is saved to the workspace.
Open for Edit
Retrieves a writable copy of the file to your workspace for editing.
  1. Select the file and click Open for Edit. The Open Files for Edit dialog box opens.

    pfopenfilesforedit2.png
  2. Specify how to replace a writeable file if one is found and click OK. The file is ready for editing.

    Note:
    'Open for edit' is a Perforce term. TestTrack does not open an editor for editing the file. You must open the file in your editor from the workspace.
Revert
Cancels the open file for edit action.
  1. Select a file that is open for edit and click Revert. The Revert Files dialog box opens.
  2. Select how to handle the local file and click OK. The file is no longer opened for edit.
Submit
Submits changes to the Perforce server. The version created by the submit is displayed in the Fixed Revision column on the item Source Code tab.

Note:
You can only submit files from the default changelist.
  1. Select the file to submit and click Submit. The Submit Files dialog box opens.

    pfsubmitfiles2.png
  2. Select any other submit options and click Submit or Submit & Fix. Perforce does not support the Comment field. Comments you enter are not included with the file changes.

    • Submit checks the file back in to the Perforce server. The version created by the check in is updated in the Source Code tab.
    • Submit & Fix is available if you are submitting changes to a file attached to a defect. If you click Submit & Fix, the Fix dialog box opens. Enter the effort time, any notes, and a resolution and click OK. The file is checked in and the defect moves to the Fix state.
  3. Click OK in the Edit window to save the changes.
View
Displays the contents of the latest version of the file on the Perforce server.
  1. Select the file you want to view and click View. The View Files dialog box opens.
  2. Select TestTrack Viewer to view the file with the TestTrack text file viewer or select Registered application to use the application associated with the selected file type in the operating system.
  3. Click OK. The file content is displayed.
History
Displays the entire file history.
  1. Select the file you want to view the history for and click History. The File History dialog box opens.

    pffilehistory2.png
  2. Click Close when you finish reviewing the file history.

Troubleshooting

See the Troubleshooting TestTrack Perforce Integration knowledgebase article.
Attachments
No attachments were found.
Related Articles

© 2011 Seapine Software, Inc., All rights reserved.