def UncreatedNamedTemporaryFile(suffix: str):
    """Makes a temp folder for a named temporary file."""
    tempdir = None  # pyright
    try:
        tempdir = mkdtemp()
        tempfile = NamedTemporaryFile(dir=tempdir, suffix=suffix)
        tempfile.__enter__()
        os.remove(tempfile.name)
        yield tempfile

    finally:
        tempfile.__exit__(None, None, None)
        if tempdir is not None:
            shutil.rmtree(tempdir)
Makes a temp folder for a named temporary file.
tests/a_scripts/data_prep/test_convert_delta_to_json.py