IBM Support

PM80566: RIT 8.0.1.1 ECMASCRIPT SUBSTITUTION OF TAG VALUES OCCURRING WHEN NOT WANTED

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • <span><span>here is a problem in RIT 8.0.1.1 which a client
    tells me was not in RIT 8.0.1.0 (and which I can confirm is not
    in GH Tester 5.4.0.14).<br/><br/>An ECMAScript action such
    as:<br/><br/>// Get curent year<br/>var d = new
    Date()<br/>''+d.getUTCFullYear()<br/><br/>This works unless
    there is a tag named &quot;Date&quot; defined (which is case
    sensitive) in which case this error
    occurs<br/><br/></span></span><br/><span><span><br/>[15:54:18.48
    3 2013/01/14] Initialising...<br/>[15:54:18.484 2013/01/14]
    Using environment: env<br/>[15:54:18.484 2013/01/14] - - - -
    Starting main steps - - - - <br/>[15:54:18.500 2013/01/14]
    [Error] Function:Run &quot;// Get curent year<br/>
    var d = new Date()<br/>
    ''+d.getUTCFullYear()&quot; , store into &quot;result&quot; An
    error occurred whilst performing the function &quot;// Get
    curent year<br/>                          var d = new
    Date()<br/>
    ''+d.getUTCFullYear()&quot;. Exception:
    sun.org.mozilla.javascript.int<span></span>ernal.EcmaError:
    TypeError:  is not a function, it is string.
    (ECMAScriptExecutor#2)<br/>[15:54:18.502 2013/01/14] [Failed] 1
    iteration completed, 1 iteration failed (1)<br/>
    Logging summary: Info (0), Warnings (0), Errors (0)<br/>
    Overall status: Failed<br/><br/>This would seem to be because
    &quot;Date&quot; is replaced with the tag value in the above
    script, and the line then becomes:<br/><br/>var d = new
    ()<br/><br/>Which leads to the error above.<br/><br/>N.B. If a
    default value is given t the Date tag, then this default value
    appears after &quot;TypeError&quot; in the above error
    message.<br/><br/>There is a work around: Avoid defining tags
    which will be replace with the ECMAScript used.</span></span>
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * Users who make use of the Function action with ECMAScript.   *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * If a user creates a test with tags that have the same name   *
    * as ECMAScript objects then if ECMAScript is used within the  *
    * function action then Tester will attempt to use the tag      *
    * object rather than the actual object. <br/><br/>For example, *
    * if the test as a tag called Date then the following line of  *
    * ECMAScript:<br/><br/>var d = new Date()<br/><br/>will fail.  *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Updated to 8.0.1.2 where this problem has been fixed.        *
    ****************************************************************
    

Problem conclusion

  • This was caused by a defect in RIT.
    

Temporary fix

Comments

APAR Information

  • APAR number

    PM80566

  • Reported component name

    RATL TEST WORKB

  • Reported component ID

    5725G7900

  • Reported release

    801

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2013-01-14

  • Closed date

    2013-02-12

  • Last modified date

    2013-02-12

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    RATL TEST WORKB

  • Fixed component ID

    5725G7900

Applicable component levels

  • R800 PSN

       UP

  • R801 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSBLQQ","label":"Rational Test Workbench"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"8.0.1","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
29 October 2021