File: fake__soundfile.py

package info (click to toggle)
pysoundfile 0.10.3%2Bpost1-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 268 kB
  • sloc: python: 1,789; makefile: 156; sh: 21
file content (24 lines) | stat: -rw-r--r-- 430 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
"""Mock module for Sphinx autodoc."""

import ctypes
import ctypes.util

# Monkey-patch ctypes to disable searching for libsndfile
ctypes.util.find_library = lambda _: NotImplemented


class ffi(object):

    def dlopen(self, _):
        return self

    def string(self, _):
        return b'not implemented'

    def sf_version_string(self):
        return NotImplemented

    SFC_GET_FORMAT_INFO = NotImplemented


ffi = ffi()