# Path: sigtools/_util.py
# def get_funcsigs():
#     def __repr__(self):
# def noop(func):
# def qualname(obj):
#     def __init__(self, *args, **kwargs):
#             def cg(func, **kwargs):
#     def __get__(self, instance, owner):
# def safe_get(obj, instance, owner):
# def iter_call(obj):
# def get_introspectable(obj, forged=True, af_hint=True, partial=True):
# def get_ast(func):
# class _Unset(object):
# class OverrideableDataDesc(object):
# UNSET = _Unset()
# 
# Path: sigtools/support.py
# def s(*args, **kwargs):
#     """Creates a signature from the given string representation of one.
# 
#     .. warning::
#         The contents of the arguments are eventually passed to `exec`.
#         Do not use with untrusted input.
# 
#     ::
# 
#         >>> from sigtools.support import s
#         >>> sig = s('a, b=2, *args, c:"annotation", **kwargs')
#         >>> sig
#         <inspect.Signature object at 0x7f15e6055550>
#         >>> print(sig)
#         (a, b=2, *args, c:'annotation', **kwargs)
#     """
#     return specifiers.signature(f(*args, **kwargs))
# 
# Path: sigtools/tests/util.py
# def conv_first_posarg(sig):
# def func_to_name(func):
# def transform_exp_sources(d, subject=None):
# def transform_real_sources(d):
#     def assertSigsEqual(self, found, expected, *args, **kwargs):
#     def assertSourcesEqual(self, found, expected, func=None, depth_order=False):
#     def downgrade_sig(self, sig):
# class SignatureTests(unittest.TestCase):


import unittest
from sigtools._util import OrderedDict as od
from sigtools.support import s
from sigtools.tests import util as tutil
            { 'a': ['func2'], 'b': ['func2'], 'c': ['func2'],
              'd': ['func1'], 'e': ['func1'], 'f': ['func1'],
              '+depths': {'func2': 0, 'func1': 1} })

    def test_implicit_missing(self):
        with self.assertRaises(ValueError):
            tutil.transform_exp_sources({0: 'abc', 'func2': 'def'})

    def test_conv(self):
        self.assertEqual(
            tutil.transform_exp_sources({1: 'abc', 2: 'def'}),
            { 'a': ['_1'], 'b': ['_1'], 'c': ['_1'],
              'd': ['_2'], 'e': ['_2'], 'f': ['_2'],
              '+depths': {'_1': 0, '_2': 1} })

    def test_func_name(self):
        def f1():
            raise NotImplementedError
        self.assertEqual(
            tutil.transform_exp_sources({f1: 'abc', 'func2': 'def'}),
            { 'a': ['f1'], 'b': ['f1'], 'c': ['f1'],
              'd': ['func2'], 'e': ['func2'], 'f': ['func2'],
              '+depths': {'f1': 0, 'func2': 1} })

    def test_implicit_func(self):
        def f1():
            raise NotImplementedError
        self.assertEqual(
            tutil.transform_exp_sources({0: 'abc', 'func2': 'def'}, subject=f1),
            { 'a': ['f1'], 'b': ['f1'], 'c': ['f1'],

# Path: sigtools/_util.py
# def get_funcsigs():
#     def __repr__(self):
# def noop(func):
# def qualname(obj):
#     def __init__(self, *args, **kwargs):
#             def cg(func, **kwargs):
#     def __get__(self, instance, owner):
# def safe_get(obj, instance, owner):
# def iter_call(obj):
# def get_introspectable(obj, forged=True, af_hint=True, partial=True):
# def get_ast(func):
# class _Unset(object):
# class OverrideableDataDesc(object):
# UNSET = _Unset()
# 
# Path: sigtools/support.py
# def s(*args, **kwargs):
#     """Creates a signature from the given string representation of one.
# 
#     .. warning::
#         The contents of the arguments are eventually passed to `exec`.
#         Do not use with untrusted input.
# 
#     ::
# 
#         >>> from sigtools.support import s
#         >>> sig = s('a, b=2, *args, c:"annotation", **kwargs')
#         >>> sig
#         <inspect.Signature object at 0x7f15e6055550>
#         >>> print(sig)
#         (a, b=2, *args, c:'annotation', **kwargs)
#     """
#     return specifiers.signature(f(*args, **kwargs))
# 
# Path: sigtools/tests/util.py
# def conv_first_posarg(sig):
# def func_to_name(func):
# def transform_exp_sources(d, subject=None):
# def transform_real_sources(d):
#     def assertSigsEqual(self, found, expected, *args, **kwargs):
#     def assertSourcesEqual(self, found, expected, func=None, depth_order=False):
#     def downgrade_sig(self, sig):
# class SignatureTests(unittest.TestCase):


# Path: sigtools/tests/test_testutil.py
import unittest
from sigtools._util import OrderedDict as od
from sigtools.support import s
from sigtools.tests import util as tutil

            { 'a': ['func2'], 'b': ['func2'], 'c': ['func2'],
              'd': ['func1'], 'e': ['func1'], 'f': ['func1'],
              '+depths': {'func2': 0, 'func1': 1} })

    def test_implicit_missing(self):
        with self.assertRaises(ValueError):
            tutil.transform_exp_sources({0: 'abc', 'func2': 'def'})

    def test_conv(self):
        self.assertEqual(
            tutil.transform_exp_sources({1: 'abc', 2: 'def'}),
            { 'a': ['_1'], 'b': ['_1'], 'c': ['_1'],
              'd': ['_2'], 'e': ['_2'], 'f': ['_2'],
              '+depths': {'_1': 0, '_2': 1} })

    def test_func_name(self):
        def f1():
            raise NotImplementedError
        self.assertEqual(
            tutil.transform_exp_sources({f1: 'abc', 'func2': 'def'}),
            { 'a': ['f1'], 'b': ['f1'], 'c': ['f1'],
              'd': ['func2'], 'e': ['func2'], 'f': ['func2'],
              '+depths': {'f1': 0, 'func2': 1} })

    def test_implicit_func(self):
        def f1():
            raise NotImplementedError
        self.assertEqual(
            tutil.transform_exp_sources({0: 'abc', 'func2': 'def'}, subject=f1),
            { 'a': ['f1'], 'b': ['f1'], 'c': ['f1'],

              'd': ['func2'], 'e': ['func2'], 'f': ['func2'],