Revision 80b207df lib/mcpu.py
b/lib/mcpu.py | ||
---|---|---|
470 | 470 |
if not (resultcheck_fn is None or resultcheck_fn(result)): |
471 | 471 |
logging.error("Expected opcode result matching %s, got %s", |
472 | 472 |
resultcheck_fn, result) |
473 |
raise errors.OpResultError("Opcode result does not match %s: %s" % |
|
474 |
(resultcheck_fn, utils.Truncate(result, 80))) |
|
473 |
if not getattr(op, "dry_run", False): |
|
474 |
# FIXME: LUs should still behave in dry_run mode, or |
|
475 |
# alternately we should have OP_DRYRUN_RESULT; in the |
|
476 |
# meantime, we simply skip the OP_RESULT check in dry-run mode |
|
477 |
raise errors.OpResultError("Opcode result does not match %s: %s" % |
|
478 |
(resultcheck_fn, utils.Truncate(result, 80))) |
|
475 | 479 |
|
476 | 480 |
return result |
477 | 481 |
|
Also available in: Unified diff