async def METHOD_NAME(self):
    records = []
    tmpdir = tempfile.mkdtemp()
    handlejson, fileobj = tempfile.mkstemp(dir=tmpdir)
    handlepy, pyfile = tempfile.mkstemp(
        prefix="op_source_test_", suffix=".py", dir=tmpdir
    )
    # Initial check to make sure parser works
    with open(fileobj, mode="w") as f:
        json.dump(FILE_DATA, f)
        f.seek(0)
    self.assertEqual(len(parser(fileobj)), 1)
    # Write parser to file
    with open(pyfile, mode="w") as p:
        p.write(
            inspect.cleandoc(
                """
                import json
                """
            )
            + "\n\n"
            + inspect.getsource(parser)
        )
        p.seek(0)
    # Now test that operation source works
    with chdir(pathlib.Path(pyfile).parent):
        # Load the records
        records = await CLI.cli(
            "list",
            "records",
            "-sources",
            "a=op",
            "-source-opimp",
            f"{pathlib.Path(pyfile).stem}:{parser.__name__}",
            "-source-args",
            fileobj,
        )
        # Make sure they're correct
        self.assertEqual(len(records), 1)
        self.assertDictEqual(
            records[0].export(),
            {
                "key": "42",
                "features": {
                    "question": "babebabe?",
                    "context": "Feeda da facea",
                    "answer_text": "dead beef",
                    "start_pos_char": 10,
                    "title": "feedface",
                    "is_impossible": False,
                    "answers": [],
                },
                "extra": {},
            },
        )
    os.close(handlejson)
    os.close(handlepy)
    shutil.rmtree(tmpdir)