#NEWLINE# def test_setuptools_include_package( self ) : #NEWLINE# #INDENT# top = self . top_node #NEWLINE# top . make_node ( 'yeah.txt' ) . write ( '' ) #NEWLINE# top . make_node ( 'foo' ) . mkdir ( ) #NEWLINE# top . find_node ( 'foo' ) . make_node ( '__init__.py' ) . write ( '' ) #NEWLINE# top . find_node ( 'foo' ) . make_node ( 'foo.info' ) . write ( '' ) #NEWLINE# top . make_node ( 'MANIFEST.in' ) . write ( 'include yeah.txt\ninclude foo/foo.info\n' ) #NEWLINE# top . make_node ( 'setup.py' ) . write ( 'import setuptools\nfrom distutils.core import setup\n\nsetup(name="foo", include_package_data=True, packages=["foo"])\n' ) #NEWLINE# monkey_patch ( top , 'setuptools' , 'setup.py' ) #NEWLINE# ( dist , package_objects ) = analyse_setup_py ( 'setup.py' , [ '-n' , '-q' ] ) #NEWLINE# ( pkg , options ) = build_pkg ( dist , package_objects , dist ) #NEWLINE# self . assertEqual ( pkg . data_files , { #NEWLINE# #INDENT# 'foo_data' : DataFiles ( 'foo_data' , [ 'foo.info' ] , '$sitedir/foo' , 'foo' ) , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . assertEqual ( pkg . extra_source_files , [ 'setup.py' , 'yeah.txt' ] )