View Issue Details

IDProjectCategoryView StatusLast Update
0005114CTT UA Scripts1 - Script Issuepublic2023-10-05 14:40
ReporterV. Monfort Assigned ToAlexander Allmendinger  
PrioritynormalSeverityminorReproducibilityalways
Status assignedResolutionopen 
PlatformLinux 
Summary0005114: View Basic 020.js test fails with valid data provided
Description

If a node is defined as:
<UAObject BrowseName="1:Node2" NodeId="ns=1;s=Node2" ParentNodeId="Node1">
<DisplayName>Node2</DisplayName>
<Description>Node2</Description>
<References>
<Reference IsForward="false" ReferenceType="Organizes">Node1</Reference>
<Reference ReferenceType="HasTypeDefinition">i=61</Reference>
<Reference ReferenceType="HasComponent">Node3</Reference>
<Reference ReferenceType="HasOrderedComponent">Node3</Reference>
</References>
</UAObject>

And this node is used as Settings.ServerTest.NodeIds.References.HasRefsOfTypeAndSubtype the obtained result is the following
ItemTypeId:i=49 is a SubType of TypeNodeId:i=47 but its inheritenceLevel(1 doesn't match the desire level (2)!
No references returned that match the test-criteria. Please check setting '/Server Test/NodeIds/References/Has References of a ReferenceType and SubType'.

It seems correct since reference types 47 (HasComponent) and 49 (HasOrderedComponent) are direct subtypes.

But if the node is defined this way:
<UAObject BrowseName="1:Node2" NodeId="ns=1;s=Node2" ParentNodeId="Node1">
<DisplayName>Node2</DisplayName>
<Description>Node2</Description>
<References>
<Reference IsForward="false" ReferenceType="Organizes">Node1</Reference>
<Reference ReferenceType="HasTypeDefinition">i=61</Reference>
<Reference ReferenceType="Aggregates">Node3</Reference>
<Reference ReferenceType="HasOrderedComponent">Node3</Reference>
</References>
</UAObject>

And this node is used as Settings.ServerTest.NodeIds.References.HasRefsOfTypeAndSubtype the obtained result is the following:
ItemTypeId:i=49 is a SubType of TypeNodeId:i=44 but its inheritenceLevel(1 doesn't match the desire level (2)!
No references returned that match the test-criteria. Please check setting '/Server Test/NodeIds/References/Has References of a ReferenceType and SubType'.

It seems incorrect since reference types 44 (Aggregates) and 49 (HasOrderedComponent) are subtypes of level 2.

Steps To Reproduce

Use given definition of node as Settings.ServerTest.NodeIds.References.HasRefsOfTypeAndSubtype and run the test 020.js

TagsNo tags attached.
Files Affected

Activities

Elliot Gawthrop

2022-01-18 14:53

reporter   ~0015764

This is still an issue in 1.4.9.398

It seems that GetTypeHierarchyHelper.Response.NodesInHierarchy.length is always 1, even, even when listOfReferenceTypeIds[z].ReferenceTypeId and listOfReferenceTypeIds[y].ReferenceTypeId have a subtype level difference of 2.

I don't understand what the code is trying to do, it looks like the level is being calculated from the call to GetTypeHierarchyHelper.Execute( { NodeToRead: listOfReferenceTypeIds[z].ReferenceTypeId } );, but surely this function needs to know the reference type which it is being compared with? How can it calculate the subtype level difference with only a single function argument?

Issue History

Date Modified Username Field Change
2019-09-27 15:27 V. Monfort New Issue
2019-09-27 16:34 Paul Hunkar Assigned To => Paul Hunkar
2019-09-27 16:34 Paul Hunkar Status new => assigned
2022-01-18 14:53 Elliot Gawthrop Note Added: 0015764
2022-08-02 20:04 Paul Hunkar Project Compliance Test Tool (CTT) Unified Architecture => CTT UA Scripts
2023-10-05 14:40 Paul Hunkar Assigned To Paul Hunkar => Alexander Allmendinger