HC error message could be improved
Summary
When a tsp(test suite parameter) is not initialized, but it is used in the TTCN code as default value of a parameter of a function, executing test cases that use the function fails. The error message displayed could be made richer to easily spot which tsps are causing the issue. Part of the error message at the moment is: "Assignment of an unbound charstring value.". It does not say which tsp or which line or which function.
Steps and/or TTCN-3 code to reproduce
- Create a tsp and do not assign default value.
- Create a function that uses the tsp as a default value of one of its parameters.
- Use the function in a TC
- Execute the test case
I have attached a TTCN file and a cfg file for this.
What is the current bug behavior?
The TC execution fails with DTE before it starts during configuring the HC. The core error message is: Dynamic test case error: Assignment of an unbound charstring value.
What is the expected correct behavior?
It would be more helpful if the error message specified (if possible)
- The line number where the problem occurs
- The function where the problem occurs
- The tsp causing the problem
Relevant logs and/or screenshots
(Paste any relevant logs - please use code blocks (```) to format console output, logs, and code, as it's very hard to read otherwise.)
spawn /proj/epg-tools/ft/ttcn3/titan/8.1.0-rhel7-gcc5.4.0/64_bit/bin/mctr_cli /workspace/git/easmgeb/Typhon1/sandbox/sandbox.cfg
*************************************************************************
* TTCN-3 Test Executor - Main Controller 2 *
* Version: 8.1.0 *
* Copyright (c) 2000-2021 Ericsson Telecom AB *
* All rights reserved. This program and the accompanying materials *
* are made available under the terms of the Eclipse Public License v2.0 *
* which accompanies this distribution, and is available at *
* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html *
*************************************************************************
Using configuration file: /workspace/git/easmgeb/Typhon1/sandbox/sandbox.cfg
MC@seroiuts02335: Unix server socket created successfully.
MC@seroiuts02335: Listening on TCP port 32775.
MC2> seroiuts02335.sero.gic.ericsson.se is the default
spawn /workspace/git/easmgeb/Typhon1/.build/sandbox_ttcn seroiuts02335.sero.gic.ericsson.se 32775
TTCN-3 Host Controller (parallel mode), version 8.1.0
MC@seroiuts02335: New HC connected from 10.117.115.90 [10.117.115.90]. seroiuts02335: Linux 3.10.0-1160.42.2.el7.x86_64 on x86_64.
cmtc
MC@seroiuts02335: Downloading configuration file to all HCs.
HC@seroiuts02335: Dynamic test case error: Assignment of an unbound charstring value.
Error: There were errors during configuring HCs.
Error during initialization. Cannot create MTC.
MC2> ttcn3_start: error: the MTC cannot be created.
exit
MC@seroiuts02335: Shutting down session.
MC@seroiuts02335: Shutdown complete.
Possible fixes
(If you can, link to the line of code that might be responsible for the problem)
Titan version
Titan 8.1.0
Platform details (OS type and version)
Red Hat Enterprise Linux Server release 7.9 (Maipo)