/*****************************************************************
 ** @author   STF 548
 ** @version  0.0.1
 ** @purpose  1:27.1.2.0, Verify that attributes from lower scopes override attribute from higher scopes
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

// The following requirement is tested:
// A with statement that is placed inside the scope of another with statement shall override the outermost with.

module Sem_27010200_general_004 {

    type component GeneralComp {
	}

	type record of universal charstring RoUC;

	testcase TC_Sem_27010200_general_004 () runs on GeneralComp {
		const integer c_zero := 0;
		var RoUC v_enc := c_zero.encode;
		if(v_enc[0] == "RuleA") {
			setverdict(pass);
		} else {
			setverdict(fail);
		}
	} with { encode "RuleA" }


	control{
		execute(TC_Sem_27010200_general_004());
	}

} with { encode "GeneralRule" }