Commit 83930e0d authored by zeiss's avatar zeiss
Browse files

No commit message

No commit message
parent 78a4158a
Loading
Loading
Loading
Loading
+29 −0
Original line number Diff line number Diff line
/*****************************************************************
 ** @author   STF 409
 ** @version  $Rev: 150 $
 ** @purpose  1:15.8, Ensure that a value can be assigned to a template variable.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1508_TemplateRestrictions_010 {

type component GeneralComp { }

testcase TC_Sem_1508_TemplateRestrictions_010() runs on GeneralComp {
	var template integer v_template;
	
	v_template := 20;
	
	if (valueof(v_template) == 20) {
		setverdict(pass);
	} else {
		setverdict(fail);
	}
}

control{
    execute(TC_Sem_1508_TemplateRestrictions_010());
}


}
 No newline at end of file
+36 −0
Original line number Diff line number Diff line
/*****************************************************************
 ** @author   STF 409
 ** @version  $Rev: 150 $
 ** @purpose  1:15.8, Ensure that a template(omit) can be assigned to a template variable.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1508_TemplateRestrictions_011 {

type component GeneralComp { }

type record ExampleType {
	integer a,
	boolean b optional
}

template(omit) ExampleType exampleOmit := {1, omit};

testcase TC_Sem_1508_TemplateRestrictions_011() runs on GeneralComp {
	var template ExampleType v_template;
	
	v_template := exampleOmit;
	
	if (match(v_template, {1,omit})) {
		setverdict(pass);
	} else {
		setverdict(fail);
	}
}

control{
    execute(TC_Sem_1508_TemplateRestrictions_011());
}


}
 No newline at end of file
+36 −0
Original line number Diff line number Diff line
/*****************************************************************
 ** @author   STF 409
 ** @version  $Rev: 150 $
 ** @purpose  1:15.8, Ensure that a template(value) can be assigned to a template variable.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1508_TemplateRestrictions_012 {

type component GeneralComp { }

type record ExampleType {
	integer a,
	boolean b optional
}

template(value) ExampleType exampleValue := {1, true};

testcase TC_Sem_1508_TemplateRestrictions_012() runs on GeneralComp {
	var template ExampleType v_template;
	
	v_template := exampleValue;
	
	if (match(v_template, {1,true})) {
		setverdict(pass);
	} else {
		setverdict(fail);
	}
}

control{
    execute(TC_Sem_1508_TemplateRestrictions_012());
}


}
 No newline at end of file
+36 −0
Original line number Diff line number Diff line
/*****************************************************************
 ** @author   STF 409
 ** @version  $Rev: 150 $
 ** @purpose  1:15.8, Ensure that a template(present) can be assigned to a template variable.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1508_TemplateRestrictions_013 {

type component GeneralComp { }

type record ExampleType {
	integer a,
	boolean b optional
}

template(present) ExampleType examplePresent := {1, true};

testcase TC_Sem_1508_TemplateRestrictions_013() runs on GeneralComp {
	var template ExampleType v_template;
	
	v_template := examplePresent;
	
	if (match(v_template, {1,true})) {
		setverdict(pass);
	} else {
		setverdict(fail);
	}
}

control{
    execute(TC_Sem_1508_TemplateRestrictions_013());
}


}
 No newline at end of file
+36 −0
Original line number Diff line number Diff line
/*****************************************************************
 ** @author   STF 409
 ** @version  $Rev: 150 $
 ** @purpose  1:15.8, Ensure that a template can be assigned to a template variable.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1508_TemplateRestrictions_014 {

type component GeneralComp { }

type record ExampleType {
	integer a,
	boolean b optional
}

template ExampleType exampleTemplate := {1, true};

testcase TC_Sem_1508_TemplateRestrictions_014() runs on GeneralComp {
	var template ExampleType v_template;
	
	v_template := exampleTemplate;
	
	if (match(v_template, {1,true})) {
		setverdict(pass);
	} else {
		setverdict(fail);
	}
}

control{
    execute(TC_Sem_1508_TemplateRestrictions_014());
}


}
 No newline at end of file