# Path: pycc/asttools/parse.py
# def parse(source, filename='<unknown>', mode='exec'):
#     """An ast.parse extension.
# 
#     This function behaves identically to the standard ast.parse except that it
#     adds parent and sibling references to each node.
#     """
#     node = ast.parse(source, filename, mode)
#     references.add_parent_references(node)
#     references.add_sibling_references(node)
# 
#     return node
# 
# Path: pycc/asttools/scope.py
# SCOPE_TYPE = enum.Enum(("MODULE", "FUNCTION", "CLASS"))
# def is_scope(node):
# def scope_type(node):
# def parent_scope(node):
# def child_scopes(node):


import pytest
from pycc.asttools import parse
from pycc.asttools import scope
"""Test suite for asttools.scope."""

from __future__ import division
from __future__ import absolute_import
from __future__ import print_function
from __future__ import unicode_literals




source = """
def test_func(d=None, *args, **kwargs):

    return d, args, kwargs

class TestClass(object):

    def test_method(self):

        pass
"""


@pytest.fixture
def node():
    """Get as AST node from the source."""

# Path: pycc/asttools/parse.py
# def parse(source, filename='<unknown>', mode='exec'):
#     """An ast.parse extension.
# 
#     This function behaves identically to the standard ast.parse except that it
#     adds parent and sibling references to each node.
#     """
#     node = ast.parse(source, filename, mode)
#     references.add_parent_references(node)
#     references.add_sibling_references(node)
# 
#     return node
# 
# Path: pycc/asttools/scope.py
# SCOPE_TYPE = enum.Enum(("MODULE", "FUNCTION", "CLASS"))
# def is_scope(node):
# def scope_type(node):
# def parent_scope(node):
# def child_scopes(node):


# Path: tests/asttools/test_scope.py
import pytest
from pycc.asttools import parse
from pycc.asttools import scope

"""Test suite for asttools.scope."""

from __future__ import division
from __future__ import absolute_import
from __future__ import print_function
from __future__ import unicode_literals




source = """
def test_func(d=None, *args, **kwargs):

    return d, args, kwargs

class TestClass(object):

    def test_method(self):

        pass
"""


@pytest.fixture
def node():
    """Get as AST node from the source."""

    return parse.parse(source)