/*****************************************************************
 ** @author   STF 487
 ** @version  0.0.1
 ** @purpose  1:22.2.3, invalid format value in @decoded redirect assignment
 ** @verdict  pass reject
 *****************************************************************/

// The following requirements are tested:
// Rules in clause 22.2.2 shall apply.
// Any other value shall cause an error.

module NegSem_220203_TriggerOperation_007 {
	type record R
    {
        integer id,
        universal charstring payload
    }

	type port P message {
		inout R;
	}

    type component GeneralComp
	{
		port P p;
	}

    testcase TC_NegSem_220203_TriggerOperation_007() runs on GeneralComp {
        var integer v_src := 1953719668, v_res with { encode "32bit" };
        var universal charstring v_str := encvalue_unichar(v_src);
        p.send(R:{ id := 1, payload := v_str });
        alt {
            [] p.trigger(R:?) -> value (v_res := @decoded("proprietary") payload) {
                setverdict (pass);
            }
        }
    }

    control {
        execute(TC_NegSem_220203_TriggerOperation_007(), 5.0);
    }
}