conformance_test/positive_tests added
[deliverable/titan.core.git] / conformance_test / positive_tests / 08_modules / 0802_module_definitions_part / 080203_importing_from_modules / 08020301_general_format_of_import / Sem_08020301_GeneralFormatOfImport_016.ttcn
1 /******************************************************************************
2 * Copyright (c) 2000-2016 Ericsson Telecom AB
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 * Adrien Kirjak – initial implementation
10 *
11 ** @version 0.0.1
12 ** @purpose 1:8.2.3.1, Verify that information about type of constant is imported together with constant
13 ** @verdict pass accept, ttcn3verdict:pass
14 *****************************************************************/
15
16 // The following requirements are tested:
17 // Restriction d:
18 // A definition is imported together with all information of referenced definitions that
19 // are necessary for the usage of the imported definition, independent of the visibility
20 // of the referenced definitions.
21 // Table 8:
22 // Possible referenced definitions for a signature: parameter types
23
24 module Sem_08020301_GeneralFormatOfImport_016 {
25
26 import from Sem_08020301_GeneralFormatOfImport_016_import { const c_test };
27
28 type component GeneralComp {}
29
30 testcase TC_Sem_08020301_GeneralFormatOfImport_016() runs on GeneralComp {
31 // type compatibility is checked during assignment: for this check, the type information for c_test
32 // should be available at this point to compile the script correctly
33 var integer v_test := c_test;
34 if (v_test == 0) { setverdict(pass); }
35 else { setverdict(fail); }
36 }
37
38 control{
39 // testing if parameter names are imported
40 execute(TC_Sem_08020301_GeneralFormatOfImport_016());
41 }
42 }
43
44
This page took 0.032092 seconds and 5 git commands to generate.