def import_module(name, deprecated=False):
with warnings.catch_warnings():<EOL><INDENT>if deprecated:<EOL><INDENT>warnings.filterwarnings("<STR_LIT:ignore>", "<STR_LIT>",<EOL>DeprecationWarning)<EOL><DEDENT>try:<EOL><INDENT>module = __import__(name, level=<NUM_LIT:0>)<EOL><DEDENT>except ImportError:<EOL><INDENT>raise TestSkipped("<STR_LIT>" + name)<EOL><DEDENT>else:<EOL><INDENT>return module<EOL><DEDENT><DEDENT>
Import the module to be tested, raising TestSkipped if it is not
    available.