@dec.skipif(_ctypes_missing, msg="Ctypes library could not be found")
    def setUp(self):
        if sys.platform == 'win32':
            if sys.version_info < (3, 5):
                file = ctypes.util.find_msvcrt()
            else:
                file = 'api-ms-win-crt-math-l1-1-0.dll'
        elif sys.platform == 'darwin':
            file = 'libm.dylib'
        else:
            file = 'libm.so'

        try:
            self.lib = ctypes.CDLL(file)
        except __HOLE__:
            # This test doesn't work on some Linux platforms (Fedora for
            # example) that put an ld script in libm.so - see gh-5370
            self.skipTest("Ctypes can't import libm.so")

        restype = ctypes.c_double
        argtypes = (ctypes.c_double,)
        for name in ['sin', 'cos', 'tan']:
            func = getattr(self.lib, name)
            func.restype = restype
            func.argtypes = argtypes
dataset/ETHPy150Open scipy/scipy/scipy/integrate/tests/test_quadpack.py/TestCtypesQuad.setUp