Commit 7f4585e0 authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Add exit_code_if_platform functions to the testlib

parent e3931f38
......@@ -217,6 +217,13 @@ def exit_code( val ):
def _exit_code( opts, v ):
opts.exit_code = v
def exit_code_if_platform( val, plat ):
return lambda opts, v=val, p=plat: _exit_code_if_platform(opts, v, p)
def _exit_code_if_platform( opts, val, plat ):
if config.platform == plat:
opts.exit_code = val
# -----
def extra_run_opts( val ):
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment