Studio:WorkspaceSetup.pl

From STRIDE Wiki
Revision as of 22:04, 2 December 2008 by Mikee (talk | contribs)
Jump to navigation Jump to search

The WorkspaceSetup.pl script (found in the STRIDE scripts directory) provides a command line tool for creating canonical STRIDE Studio workspaces suitable for organizing your test scripts. This script requires perl for execution as well as the STRIDE Test Utilities.

Usage

Summary

WorkspaceSetup.pl -w MyWorkspace -d "MyDir" -f fxname [-g fxdir -p pkg -q pkgdir -s customsettings -c customconfig -l]
Parameters
-w | --workspacename = WorkspaceName
Specifies the name new workspace to be created. This workspace will be created in the directory specified by the --dirworkspace argument or in the current directory (if no workspace directory is specified). Defaults to 'MyWorkspace'.
-d | --dirworkspace = WorkspaceDirectory
Specifies the directory in which to create the new workspace. Defaults to the current directory.
-c | --workspaceconfig = MyConfig.pm
Allows users to specify a different WorkspaceConfig file to use when creating the workspace. This allows framework users to generate a workspace with custom config parameters.
-l | --launch
Launches STRIDE Studio and opens the newly created workspace.

Workspace Layout

The workspaces that are created by WorkspaceSetup will have the following files and folders (items in <brackets> indicate folders):

 < Script Files > 
   <setup>
     StartPrintLog.pl
   <test> 
   <teardown>
     StopPrintLog.pl
     TweakResults.pl
   <utility>
     <recovery>
       s2OnError.pl
 < Source Files >


setup Folder

This folder is intended to contain the scripts necessary to prepare the device for testing. For the canonical workspace, we add a script that opens a traceview to capture srPrint* output messages. Users might choose to add scripts for starting and initializing the device under test.

test Folder

This folder is intended to contain the test scripts to be executed on the device. It is created by this setup and test script writers are free to organize test scripts however they want in this folder. This folder also has the "OnRunConnect" property set to true so that a target connection will be initiated when it is executed. The connection is established using your global connection settings (see STRIDE Studio reference guide for more information).

teardown Folder

This folder contains the scripts necessary to cleanup after testing is completed. This might involve, for example, stopping the device. The canonical workspace contains one script to process the srPrint* info sent to the logging traceview and another to adjust the hierarchy of the final report results.

utility Folder

This folder should be used to hold utility libraries that are associated with the workspace. This directory is not included in execution; as such, the files therin are provided for convenience to the users.

recovery Folder

This folder contains the sample s2OnError script that we provide. This is intended as a template for customization depending on your device's needs.

See Also