def METHOD_NAME():
    ''' Check that the validate() method works as expected. '''
    trans = CreateNemoInvokeScheduleTrans()
    with pytest.raises(TransformationError) as err:
        trans.validate(Return())
    assert ("supplied node should be a PSyIR Routine but found 'Return'" in
            str(err.value))