We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Creating Integration Tests needs an example plug-in
We have test code here, without the corresponding tested code: http://docs.pylonsproject.org/projects/pyramid/en/latest/narr/testing.html#creating-integration-tests. It would be good to see what it would look like.


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `docs/narr/MyProject/setup.py`
Content:
```
1 import os
2 
3 from setuptools import setup, find_packages
4 
5 here = os.path.abspath(os.path.dirname(__file__))
6 with open(os.path.join(here, 'README.txt')) as f:
7     README = f.read()
8 with open(os.path.join(here, 'CHANGES.txt')) as f:
9     CHANGES = f.read()
10 
11 requires = [
12     'pyramid',
13     'pyramid_chameleon',
14     'pyramid_debugtoolbar',
15     'waitress',
16     ]
17 
18 setup(name='MyProject',
19       version='0.0',
20       description='MyProject',
21       long_description=README + '\n\n' + CHANGES,
22       classifiers=[
23         "Programming Language :: Python",
24         "Framework :: Pyramid",
25         "Topic :: Internet :: WWW/HTTP",
26         "Topic :: Internet :: WWW/HTTP :: WSGI :: Application",
27         ],
28       author='',
29       author_email='',
30       url='',
31       keywords='web pyramid pylons',
32       packages=find_packages(),
33       include_package_data=True,
34       zip_safe=False,
35       install_requires=requires,
36       tests_require=requires,
37       test_suite="myproject",
38       entry_points="""\
39       [paste.app_factory]
40       main = myproject:main
41       """,
42       )
43
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/docs/narr/MyProject/setup.py b/docs/narr/MyProject/setup.py
--- a/docs/narr/MyProject/setup.py
+++ b/docs/narr/MyProject/setup.py
@@ -1,30 +1,42 @@
-import os
+"""Setup for the MyProject package.
 
+"""
+import os
 from setuptools import setup, find_packages
 
-here = os.path.abspath(os.path.dirname(__file__))
-with open(os.path.join(here, 'README.txt')) as f:
-    README = f.read()
-with open(os.path.join(here, 'CHANGES.txt')) as f:
-    CHANGES = f.read()
 
-requires = [
+HERE = os.path.abspath(os.path.dirname(__file__))
+
+
+with open(os.path.join(HERE, 'README.txt')) as fp:
+    README = fp.read()
+
+
+with open(os.path.join(HERE, 'CHANGES.txt')) as fp:
+    CHANGES = fp.read()
+
+
+REQUIRES = [
     'pyramid',
     'pyramid_chameleon',
     'pyramid_debugtoolbar',
     'waitress',
     ]
 
+TESTS_REQUIRE = [
+    'webtest'
+    ]
+
 setup(name='MyProject',
       version='0.0',
       description='MyProject',
       long_description=README + '\n\n' + CHANGES,
       classifiers=[
-        "Programming Language :: Python",
-        "Framework :: Pyramid",
-        "Topic :: Internet :: WWW/HTTP",
-        "Topic :: Internet :: WWW/HTTP :: WSGI :: Application",
-        ],
+          'Programming Language :: Python',
+          'Framework :: Pyramid',
+          'Topic :: Internet :: WWW/HTTP',
+          'Topic :: Internet :: WWW/HTTP :: WSGI :: Application',
+      ],
       author='',
       author_email='',
       url='',
@@ -32,11 +44,10 @@
       packages=find_packages(),
       include_package_data=True,
       zip_safe=False,
-      install_requires=requires,
-      tests_require=requires,
-      test_suite="myproject",
+      install_requires=REQUIRES,
+      tests_require=TESTS_REQUIRE,
+      test_suite='myproject',
       entry_points="""\
       [paste.app_factory]
       main = myproject:main
-      """,
-      )
+      """)

{"golden_diff": "diff --git a/docs/narr/MyProject/setup.py b/docs/narr/MyProject/setup.py\n--- a/docs/narr/MyProject/setup.py\n+++ b/docs/narr/MyProject/setup.py\n@@ -1,30 +1,42 @@\n-import os\n+\"\"\"Setup for the MyProject package.\n \n+\"\"\"\n+import os\n from setuptools import setup, find_packages\n \n-here = os.path.abspath(os.path.dirname(__file__))\n-with open(os.path.join(here, 'README.txt')) as f:\n-    README = f.read()\n-with open(os.path.join(here, 'CHANGES.txt')) as f:\n-    CHANGES = f.read()\n \n-requires = [\n+HERE = os.path.abspath(os.path.dirname(__file__))\n+\n+\n+with open(os.path.join(HERE, 'README.txt')) as fp:\n+    README = fp.read()\n+\n+\n+with open(os.path.join(HERE, 'CHANGES.txt')) as fp:\n+    CHANGES = fp.read()\n+\n+\n+REQUIRES = [\n     'pyramid',\n     'pyramid_chameleon',\n     'pyramid_debugtoolbar',\n     'waitress',\n     ]\n \n+TESTS_REQUIRE = [\n+    'webtest'\n+    ]\n+\n setup(name='MyProject',\n       version='0.0',\n       description='MyProject',\n       long_description=README + '\\n\\n' + CHANGES,\n       classifiers=[\n-        \"Programming Language :: Python\",\n-        \"Framework :: Pyramid\",\n-        \"Topic :: Internet :: WWW/HTTP\",\n-        \"Topic :: Internet :: WWW/HTTP :: WSGI :: Application\",\n-        ],\n+          'Programming Language :: Python',\n+          'Framework :: Pyramid',\n+          'Topic :: Internet :: WWW/HTTP',\n+          'Topic :: Internet :: WWW/HTTP :: WSGI :: Application',\n+      ],\n       author='',\n       author_email='',\n       url='',\n@@ -32,11 +44,10 @@\n       packages=find_packages(),\n       include_package_data=True,\n       zip_safe=False,\n-      install_requires=requires,\n-      tests_require=requires,\n-      test_suite=\"myproject\",\n+      install_requires=REQUIRES,\n+      tests_require=TESTS_REQUIRE,\n+      test_suite='myproject',\n       entry_points=\"\"\"\\\n       [paste.app_factory]\n       main = myproject:main\n-      \"\"\",\n-      )\n+      \"\"\")\n", "issue": "Creating Integration Tests needs an example plug-in\nWe have test code here, without the corresponding tested code: http://docs.pylonsproject.org/projects/pyramid/en/latest/narr/testing.html#creating-integration-tests. It would be good to see what it would look like.\n\n", "before_files": [{"content": "import os\n\nfrom setuptools import setup, find_packages\n\nhere = os.path.abspath(os.path.dirname(__file__))\nwith open(os.path.join(here, 'README.txt')) as f:\n    README = f.read()\nwith open(os.path.join(here, 'CHANGES.txt')) as f:\n    CHANGES = f.read()\n\nrequires = [\n    'pyramid',\n    'pyramid_chameleon',\n    'pyramid_debugtoolbar',\n    'waitress',\n    ]\n\nsetup(name='MyProject',\n      version='0.0',\n      description='MyProject',\n      long_description=README + '\\n\\n' + CHANGES,\n      classifiers=[\n        \"Programming Language :: Python\",\n        \"Framework :: Pyramid\",\n        \"Topic :: Internet :: WWW/HTTP\",\n        \"Topic :: Internet :: WWW/HTTP :: WSGI :: Application\",\n        ],\n      author='',\n      author_email='',\n      url='',\n      keywords='web pyramid pylons',\n      packages=find_packages(),\n      include_package_data=True,\n      zip_safe=False,\n      install_requires=requires,\n      tests_require=requires,\n      test_suite=\"myproject\",\n      entry_points=\"\"\"\\\n      [paste.app_factory]\n      main = myproject:main\n      \"\"\",\n      )\n", "path": "docs/narr/MyProject/setup.py"}], "after_files": [{"content": "\"\"\"Setup for the MyProject package.\n\n\"\"\"\nimport os\nfrom setuptools import setup, find_packages\n\n\nHERE = os.path.abspath(os.path.dirname(__file__))\n\n\nwith open(os.path.join(HERE, 'README.txt')) as fp:\n    README = fp.read()\n\n\nwith open(os.path.join(HERE, 'CHANGES.txt')) as fp:\n    CHANGES = fp.read()\n\n\nREQUIRES = [\n    'pyramid',\n    'pyramid_chameleon',\n    'pyramid_debugtoolbar',\n    'waitress',\n    ]\n\nTESTS_REQUIRE = [\n    'webtest'\n    ]\n\nsetup(name='MyProject',\n      version='0.0',\n      description='MyProject',\n      long_description=README + '\\n\\n' + CHANGES,\n      classifiers=[\n          'Programming Language :: Python',\n          'Framework :: Pyramid',\n          'Topic :: Internet :: WWW/HTTP',\n          'Topic :: Internet :: WWW/HTTP :: WSGI :: Application',\n      ],\n      author='',\n      author_email='',\n      url='',\n      keywords='web pyramid pylons',\n      packages=find_packages(),\n      include_package_data=True,\n      zip_safe=False,\n      install_requires=REQUIRES,\n      tests_require=TESTS_REQUIRE,\n      test_suite='myproject',\n      entry_points=\"\"\"\\\n      [paste.app_factory]\n      main = myproject:main\n      \"\"\")\n", "path": "docs/narr/MyProject/setup.py"}]}