TestOptimal Wiki

Model-Based Testing (MBT)

User Tools

Site Tools


Generate TestCase Report

SeqOut plugin allows you to quickly generate test steps for manual testing or documentation of test cases executed.

Output Format

You may output test case in HTML webpage or Microsoft Excel document. To select which format to use, open Model Property dialog and in field “Plugins” select SeqOutHTML or SeqOutExcel by checking the appropriate check box. Be sure to have other plugins unchecked. Click “OK” to save the changes.

Optionally you can edit the Test Case Output field to the desired file name.

Generate Test Case

With SeqOut plugin activated for the model, now you can run the model. When model execution completes, you can open the test case document generated by clicking on menu Report/TestCase Report. Depending on the format you have chosen, the test case report should open in your browser or in Microsoft Excel.

See this example output at example output.

Style Test Case Report

You can style the test case report web page by editing /www/MbtSvr/config/seqout.css (Casscade Style Sheet).

Your changes will take effective on new test case report generation.

If you want to make the style changes to existing test case report already generated, you can manually copy seqout.css to each indiviudal test case report folder under model's report folder.

Customize Test Step Format

The format of the test step text may be customized also. seqout.fmt determines the text format for each test case step instruction in the test case report. In this file, you will see that the format definition for each mscript function and tag.

TestOptimal allows you to change the format to meet your convention and style. Follow the following steps to apply your customization:

  • make a copy of a sample seqoutDDI.fmt in the config folder. Say you name the new file mySeqOut.fmt.
  • for each MScript function or tag, copy their original definition from seqout.fmt and paste it to your customization format file mySeqOut.fmt. Change the format to the way you want and save the changes.
  • edit config.properties file in config folder, replace all occurrences of seqout.fmt with mySeqOut.fmt. Save the changes.
  • restart TestOptimal server to make the changes effective.
  • re-run your model and you should notice the test case report generated has the your modified formats.

Format Keywords

SeqOut plugin uses a set of keywords matching the MScript tag and functions.

MScript Tags
  • ACTION: format for mScript Action tag. Also used to output certain system methods
  • ACTION_END: static text to close ACTION
  • ASSERT: format for mScript Assert tag
  • IF: format for mScript If tag
  • IF_END: static text to close IF
  • LOG: format for mScript Log tag
  • WHILE: format for mScript While tag
  • WHILE_END: static text to close WHILE
MScript Functions
  • addTagCheck
  • click
  • closeWindow
  • containsText
  • count
  • doubleClick
  • dragAndDrop
  • flashGetVariable
  • getAlertText
  • getAttr
  • getConfirmText
  • getAllWindowsID
  • getCookie
  • getText
  • getTitle
  • gotoURL
  • isAlertPresent
  • isChecked
  • isConfirmPresent
  • isDisabled
  • isPresent
  • isVisible
  • mouseDown
  • mouseOver
  • mouseUp
  • refresh
  • rightClick
  • selectFrame
  • selectOption
  • setCheckBox
  • setRadioButton
  • setupConfirmResponse
  • sizeOf
  • snapScreen
  • type
  • sleep
  • waitForPageToLoad
  • windowName_p
Replacement Token
  • @ATTR@: attr from mScript methods from getAttr()
  • @CODE: code from mScript Action tag
  • @CTRL@: control keys pressed from mScript methods
  • @ELSE@: else from mScript tags
  • @FROM@: from locator from mScript method dragAndDrop()
  • @LEVEL@: log level from mScript Log tag
  • @LOCATOR@: locator attribute from mScript methods
  • @MAXLOOP@: max loop number from mScript While tag
  • @MILLIS@: number of millieseonds from mScript method calls
  • @MSG@: log message from mScript Log tag
  • @NAME@: name from mScript methods getCookie() and selectFrame()
  • @OP@: op from mScript tags
  • @OPTION@: option value from mScript
  • @PASSED@: passed from mScript methods
  • @TO@: to locator from mScript method dragAndDrop()
  • @URL@: url from mScript gotoURL()
  • @VALUE@: value from mScript method
  • @VALUE1@: value1 from mScript tags
  • @VALUE2@: value2 from mScript tags
  • @TAG@: tag from mScript method addTagCheck()

Create My Own Test Case Report

SeqOut plugin uses xsl to create test case report. You may create your own test case report by writing your own xsl report.

To create your own test case report using xsl, use seqout.xsl in config folder as an example. Once you have created your own xsl report, you must change config.properties to use your xsl report for test case generation. To do so, replace seqout.xsl with the file name of your xsl report file. You must restart TestOptimal server to make your changes effective.

Custom Fields

You may define custom fields and use them in the output generation in xsl file. All custom field must start with a prefix @ char in the format file. For example:

  @Company=My Company

Your can call out these custom fields with the following xsl statement:

      <xsl:value-of select="fieldList/field[name='Company']/value"/>

Notice that in xsl statement above, the custom field is referenced with out the prefix @.

seqoutformat.txt · Last modified: 2016/09/22 02:36 (external edit)