cornercorner
FeaturesPluginsDocs & SupportCommunityPartners

ClearCase Profile Test Specification for Generic VCS Module

Author: Jiri Kovalsky
Version: 1.0
Last update: Tue April 1 18:40:14 CET 2003

Table of Contents


1. Introduction

    Rational's ClearCase tool is one of supported version control systems in the IDE. This document describes how ClearCase profile for Generic VCS module should be tested in order to know whether all of its commands work correctly.

Legend:
This test case is part of validation suite. - this icon represents a test case that is part of validation suite and is used during Q-build testing.
This test case is automated. - this icon represents a test case that was automated and is run daily in test runtime.

2. Environment setup:

    Before proceeding with further sections it is essential to have ClearCase installed successfully and working environment initiated. Skip this section if you have already a VOB tag mounted.

    1. Preparation
    • Create /opt/atria directory.
    • Unzip ClearCase distribution into /opt/atria directory.
    • 'cd /opt/atria/v4.2/install'
    • Find out $MACHINE name through 'uname' command.

    2. Installation
    • Run './site_prep'
    • Use $MACHINE as an answers for the first three questions
    • Use cc_unix_region for the fourth question.
    • Use default No answers for remaining questions.
    • Update /etc/services file accordingly.
    • Run './install_release'
    • Select full copy install to /usr/atria directory and follow the instructions.

    3. Environment setup
    • Become ordinary user.
    • Set $PATH environment variable to include cleartool binary.

    4. VOB creation
    • Create /space/clearcase/repo/repo1 directory and 'cd' there.
    • Run 'cleartool mkstgloc -vob Repo_1 /space/clearcase/repo/repo1' command.
    • Type 'yes' and press ENTER.

    5. TAG creation
    • Create /space/clearcase/work/work1 directory.
    • Run 'cleartool mkvob -tag /space/clearcase/work/work1 -stgloc -auto' command.
    • Type in 'This is tag for default vob.', press ENTER, type '.' and press ENTER.

    6. VIEW creation
    • Create /space/clearcase/view/view1 directory.
    • Run 'cleartool mkstgloc -view View_1 /space/clearcase/view/view1' command.
    • Type 'yes' and press ENTER.
    • Run 'cleartool mkview -tag View_1 -stgloc -auto' command.

    7. Mount TAG
    • Run 'cleartool mount /space/clearcase/work/work1' command.
    • Run 'cleartool setview View_1' command.
    • Use /space/clearcase/work/work1 as working directory in mounting wizard.

    8. Ordinary work
    • Run 'cd /space/clearcase/work/work1' command.
    • Run 'cleartool co .' command.
    • Type 'Initial checkout.", press ENTER, type '.' and press ENTER.
    • Create some file e.g. 'touch A_File.java'.
    • Run 'cleartool mkelem A_File.java' command.
    • Type 'Initial revision of the file.", press ENTER, type '.' and press ENTER.
    • Run 'cleartool ci .' command, type '.' and press ENTER.
    • Run 'cleartool ls' command. This must be its answer:


    • A_File.java@@/main/CHECKEDOUT from /main/0 Rule: CHECKEDOUT
      lost+found@@/main/0 Rule: /main/LATEST

3. Mount ClearCase filesystem

Purpose: This suite tests whether it is possible to mount ClearCase filesystem.
Setup: Be sure to have Rational ClearCase 5.0 installed on your computer and VOB tab is created. See previous section.

Test case # Description
3.1 ClearCase settings available
This test case is part of validation suite.
1. Invoke Versioning | Mount Version Control | Generic VCS from main menu.
2. Choose proposed ClearCase profile from the list suitable for your operating system.
3. Verify that "Working Directory" and "Relative Mount Point" textfields remained in the dialog.
3.2 ClearCase connected
This test case is part of validation suite.
1. Setup "Working Directory" to the VOB tag you prepared i.e. space/clearcase/work/work1.
2. Push "Finish" button.

4. Repository creation

Purpose: This suite tests whether it is possible to upload source code into ClearCase repository. It is essential to start version control over new files in order to work with them later on a daily basis.
Setup: The VOB tag must be mounted and VIEW must be set.

Test case # Description
4.1 Single file addition
This test case is part of validation suite.
1. Invoke New | Java Class on the filesystem. Set the name to A_File and push "Finish" button.
2. Invoke ClearCase | Add to Source Control action on "A_File [Local]" node.
3. Type "Generated A_File class." as reason and push "OK" button.
4.2 Directory addition
This test case is part of validation suite.
1. Invoke ClearCase | Create Directory action on the filesystem node.
2. Type test as "Directory Name" and push "OK" button.
4.3 Multiple file addition
This test case is part of validation suite.
1. Invoke New | Java Class on the filesystem root. Set the name to B_File and push "Finish" button.
2. Invoke New | JFrame Form on "test [CHECKEDOUT]" node. Set the name to C_File and push "Finish" button.
3. Get back to "Editing" workspace and select both [Local] nodes by CTRL key as multiselection.
4. Invoke ClearCase | Add to Source Control action.
5. Type "Generated objects." as reason and push "OK" button.

5. Regular development

Purpose: This suite tests the most often used commands of typical ClearCase user.
Setup: No preparation required.

Test case # Description
5.1 Modify a file
This test case is part of validation suite.
1. Open A_File.java and insert brand-new line somewhere into the file.
2. Delete some other line but not directly next to the new line.
3. Modify another line but not directly next to the lines mentioned above and Save the file.
5.2 View differences
This test case is part of validation suite.
1. Invoke ClearCase | Compare With Previous Version on "A_File [Locally Modified]" node.
5.3 Checkin a file
This test case is part of validation suite.
1. Invoke ClearCase | Check In on "A_File [Locally Modified]" node.
2. Setup "Three lines have changed." as "Reason" and push "OK" button.
5.4 Undo Checkout a file
This test case is part of validation suite.
1. Invoke ClearCase | Undo Checkout on "C_File [CHECKEDOUT]" node.
5.5 Inspect the file
This test case is part of validation suite.
1. Invoke ClearCase | History (Text) on "A_File [/main/1]" node.
2. Something like this must show in "Output of VCS Commands" window:

02-Apr.16:58 jk110465 create version "A_File.java@@/main/1"
   "Three lines have changed."
02-Apr.13:13 jk110465 create version "A_File.java@@/main/0"
02-Apr.13:13 jk110465 create branch "A_File.java@@/main"
02-Apr.13:13 jk110465 create file element "A_File.java@@"
5.6 Unreserve a file
This test case is part of validation suite.
1. Invoke ClearCase | Unreserve on "B_File [CHECKEDOUT]" node.
2. Invoke ClearCase | History (Text) on "B_File [CHECKEDOUT]" node.
3. Something like this must show as the first line in "Output of VCS Commands" window:

02-Apr.19:28 jk110465 checkout version "B_File.java" from /main/0 (unreserved)
5.7 Reserved checkout
This test case is part of validation suite.
1. Invoke ClearCase | Check Out Reserved on "C_File [/main/0]" node.
2. Setup "I need it !" as "Reason" and push "OK" button.
3. Invoke ClearCase | History (Text) on "C_File [CHECKEDOUT]" node.
4. There must be lines like this in "Output of VCS Commands" window:

02-Apr.19:28 jk110465 checkout version "C_File.java" from /main/0 (reserved)
   "I need it !"
02-Apr.19:28 jk110465 checkout version "C_File.form" from /main/0 (reserved)
   "I need it !"

6. Advanced commands

Purpose: This suite tests functionality of other ClearCase commands and workflows.
Setup: No preparation required.

Test case # Description
6.1 Reserve a file
1. Invoke ClearCase | Reserve on "B_File [CHECKEDOUT]" node.
2. Invoke ClearCase | History (Text) on "B_File [CHECKEDOUT]" node.
3. There must be lines like this in "Output of VCS Commands" window:

02-Apr.20:30 jk110465 checkout version "B_File.java" from /main/0 (reserved)
   "Generated objects."
6.2 Unreserved checkout
1. Invoke ClearCase | Check Out Unreserved on "A_File [/main/1]" node.
2. Setup "Need r/w copy." as "Reason" and push "OK" button.
3. Invoke ClearCase | History (Text) on "A_File [CHECKEDOUT]" node.
4. There must be lines like this in "Output of VCS Commands" window:

02-Apr.20:31 jk110465 checkout version "A_File.java" from /main/1 (unreserved)
   "Need r/w copy."
6.3 Find checkouts
1. Invoke ClearCase | Find Checked Out Recursively on "test [CHECKEDOUT]" node.
2. There must be lines like this in "Output of VCS Commands" window:

02-Apr.20:31 jk110465 checkout version "test/B_File.java" from /main/0 (reserved)
   "Generated objects."
02-Apr.20:31 jk110465 checkout version "test/C_File.java" from /main/0 (reserved)
   "I need it !."
02-Apr.20:31 jk110465 checkout version "test/C_File.form" from /main/0 (reserved)
   "I need it !."
6.4 Remove a file
1. Invoke ClearCase | Undo Checkout on "B_File [CHECKEDOUT]" node.
2. Invoke ClearCase | Remove Name from Directory on both "B_File [/main/0]" and "C_File [CHECKEDOUT]" nodes.
3. Setup "Good bye." as "Reason" and push "OK" button.
6.5 Remove a directory
1. Invoke ClearCase | Remove Directory Name from Directory on "test [CHECKEDOUT]" node.
2. Setup "Good bye." as "Reason" and push "OK" button.
6.6 List all records in view
1. Invoke ClearCase | Find All Checked Out in View on filesystem node.
6.7 Virtual nodes
1. Invoke Delete on "A_File [CHECKEDOUT]" node and confirm the question dialog.
2. Invoke ClearCase | Refresh on filesystem node.
3. Invoke ClearCase | Undo Checkout on "A_File [CHECKEDOUT REMOVED]" node.

7. Additional features

Purpose: This suite tests other features of ClearCase like merging tool, version tree etc.
Setup: No preparation required.

Test case # Description
7.1 Graphical history
1. Invoke ClearCase | History (Graphical) on "A_File [/main/1]" node.
2. Special ClearCase window "History of: A_file.java" should open containing the same information as in test case 5.5.
7.2 Version tree
1. Invoke ClearCase | Version Tree (Graphical) on "A_File [/main/1]" node.
2. Special ClearCase window "Vtree Browser" should open containing graphical diagram of history of A_File.java.
7.3 Version properties
1. Invoke ClearCase | Properties Of Version on "A_File [/main/1]" node.
2. Special ClearCase tabbed window "A_File.java" should open containing various properties version 1 of A_File.java.
7.4 Merge tool
1. Invoke ClearCase | Start a Merge on "A_File [/main/1]" node.
2. Special ClearCase window "ClearCase Merge Manager" should open with error because there are no conflicts in A_File.java currently.

Any comments and suggestions please send to Jiri Kovalsky.

Companion
Projects:
MySQL Database Server   GlassFish Community: an Open Source Application Server   Open Solaris  Open JDK: an Open SourceJDK   Mobile & Embedded Community     Sponsored by 
Sponsored by Sun Microsystems