View Issue Details

IDProjectCategoryView StatusLast Update
0004445Compliance Test Tool (CTT) Unified Architecture1 - Script Issuepublic2019-07-25 15:16
ReporterBernd Edlinger Assigned ToAlexander Allmendinger  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
PlatformPCOSWindowsOS Version8.1
Product Version1.03.341.383 
Target Version1.03Fixed in Version1.03.341.383 
Summary0004445: Attribute Write Values/initialize.js leaves sessions open
Description

Whenever I execute any test case in Attribute Services/Attribute Write Values
the CTT leaks one session, which makes the Nano embedded UA server fail
to accept additional sessions in subsequent scripts.

I tried this modified script, and it seems to work:

--- "maintree/Attribute Services/Attribute Write Values/Test Cases/initialize.js" 2018-11-06 18:09:42.000000000 +0100
+++ initialize.js 2018-11-09 10:53:18.066432470 +0100
@@ -6,11 +6,11 @@

addLog( "TESTING AN -- OPTIONAL -- CONFORMANCE UNIT" );

-// read the original values of all scalar types, because we will revert to their original values at the end of the test
-var originalScalarValues = MonitoredItem.fromSettings( Settings.ServerTest.NodeIds.Static.AllProfiles.Scalar.Settings );
-if( originalScalarValues !== null && originalScalarValues.length !== 0 ) {

  • if( !Test.Connect() ) stopCurrentUnit();
  • else {
    +if( !Test.Connect() ) stopCurrentUnit();
    +else {
  • // read the original values of all scalar types, because we will revert to their original values at the end of the test
  • var originalScalarValues = MonitoredItem.fromSettings( Settings.ServerTest.NodeIds.Static.AllProfiles.Scalar.Settings );
  • if( originalScalarValues !== null && originalScalarValues.length !== 0 ) {
    if( !ReadHelper.Execute( { NodesToRead: originalScalarValues } ) ) {
    addError( "Unable to read the initial values of the test nodes. Aborting testing." );
    stopCurrentUnit();
    @@ -20,13 +20,10 @@
    Test.PostTestFunctions.push( revertToOriginalValues );
    }
    }
    -}

-// read the original values of all array types, because we will revert to their original values at the end of the test
-var originalArrayValues = MonitoredItem.fromSettings(Settings.ServerTest.NodeIds.Static.AllProfiles.Arrays.Settings);
-if ( originalArrayValues !== null && originalArrayValues.length !== 0 ) {

  • if ( !Test.Connect() ) stopCurrentUnit();
  • else {
  • // read the original values of all array types, because we will revert to their original values at the end of the test
  • var originalArrayValues = MonitoredItem.fromSettings(Settings.ServerTest.NodeIds.Static.AllProfiles.Arrays.Settings);
  • if ( originalArrayValues !== null && originalArrayValues.length !== 0 ) {
    if (!ReadHelper.Execute( { NodesToRead: originalArrayValues } ) ) {
    addError( "Unable to read the initial values of the test nodes. Aborting testing." );
    stopCurrentUnit();
TagsNo tags attached.
Files Affected

Activities

Alexander Allmendinger

2018-12-17 15:48

developer   ~0009721

Restructuring the initialize to only call Test.Connect() once solves the issue.

Paul Hunkar

2019-07-25 15:16

administrator   ~0010609

Reviewed in CMP Call

Issue History

Date Modified Username Field Change
2018-11-09 10:10 Bernd Edlinger New Issue
2018-11-09 14:25 Paul Hunkar Assigned To => Alexander Allmendinger
2018-11-09 14:25 Paul Hunkar Status new => assigned
2018-12-17 15:48 Alexander Allmendinger Note Added: 0009721
2018-12-17 15:48 Alexander Allmendinger Status assigned => resolved
2018-12-17 15:48 Alexander Allmendinger Fixed in Version => 1.03.341.383
2018-12-17 15:48 Alexander Allmendinger Resolution open => fixed
2019-01-28 14:10 Paul Hunkar Category Script Issue => 1 - Script Issue
2019-07-25 15:16 Paul Hunkar Target Version => 1.03
2019-07-25 15:16 Paul Hunkar Status resolved => closed
2019-07-25 15:16 Paul Hunkar Note Added: 0010609