Exemple #1
0
 def testDefaultSdistTxt(self):
     st = Setuptools(Process(quiet=True))
     self.destroy(self.clonedir)
     # This uses ??? to create the manifest. Note that the .txt file
     # is missing from the archive.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'subversion_only.txt'), False)
    def testNoneManifest(self):
        st = Setuptools(Process(quiet=True, env=get_env()))
        archive = st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='none')
        self.assertEqual(get_manifest(archive), """\
README.txt
setup.py
testpackage/__init__.py
testpackage/git_only.py
testpackage.egg-info/PKG-INFO
testpackage.egg-info/SOURCES.txt
testpackage.egg-info/dependency_links.txt
testpackage.egg-info/not-zip-safe
testpackage.egg-info/requires.txt
testpackage.egg-info/top_level.txt""")
Exemple #3
0
    def testSubversionManifest(self):
        st = Setuptools(Process(quiet=True))
        # This uses svn to create the manifest.
        archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], scmtype='svn')
        self.assertEqual(get_manifest(archive), """\
README.txt
setup.py
testpackage/__init__.py
testpackage/subversion_only.py
testpackage/subversion_only.txt
testpackage.egg-info/PKG-INFO
testpackage.egg-info/SOURCES.txt
testpackage.egg-info/dependency_links.txt
testpackage.egg-info/not-zip-safe
testpackage.egg-info/requires.txt
testpackage.egg-info/top_level.txt""")
Exemple #4
0
    def testGitManifest(self):
        st = Setuptools(Process(quiet=True, env=get_env()))
        archive = st.run_dist(self.packagedir, [],
                              'sdist', ['--formats=zip'],
                              ff='git')
        self.assertEqual(
            get_manifest(archive), """\
README.txt
setup.py
testpackage/__init__.py
testpackage/git_only.c
testpackage/git_only.py
testpackage/git_only.txt
testpackage.egg-info/PKG-INFO
testpackage.egg-info/SOURCES.txt
testpackage.egg-info/dependency_links.txt
testpackage.egg-info/not-zip-safe
testpackage.egg-info/requires.txt
testpackage.egg-info/top_level.txt""")
Exemple #5
0
    def testGitManifest(self):
        st = Setuptools(Process(quiet=True))
        self.clone()
        # This uses git to create the manifest.
        archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"], scmtype="git")
        self.assertEqual(
            get_manifest(archive),
            """\
README.txt
setup.py
testpackage/__init__.py
testpackage/git_only.py
testpackage/git_only.txt
testpackage.egg-info/PKG-INFO
testpackage.egg-info/SOURCES.txt
testpackage.egg-info/dependency_links.txt
testpackage.egg-info/not-zip-safe
testpackage.egg-info/requires.txt
testpackage.egg-info/top_level.txt""",
        )
Exemple #6
0
 def testDefaultSdistPy(self):
     st = Setuptools(Process(quiet=True))
     self.destroy(self.clonedir)
     # This uses ??? to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'subversion_only.py'), True)
Exemple #7
0
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     self.clone()
     st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], scmtype='git')
     self.failIf(isfile(join(self.clonedir, 'setup.pyc')))
Exemple #8
0
 def testGitSdistTxt(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     self.clone()
     # This uses git to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'git_only.txt'), True)
 def testDefaultSdistC(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     self.destroy(self.clonedir)
     # Use the default file-finder to create the manifest; .c file is missing.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'subversion_only.c'), False)
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='none')
     self.assertFalse(isfile(join(self.packagedir, 'setup.pyc')))
 def testManifestSdistC(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='none')
     self.assertEqual(contains(archive, 'git_only.c'), True)
 def testInfoFlags(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, st.infoflags, 'sdist', ['--formats=zip'], ff='git')
     self.assertEqual(contains(archive, 'git_only.py'), True)
Exemple #13
0
 def testMercurialSdistTxt(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [],
                           'sdist', ['--formats=zip'],
                           ff='hg')
     self.assertEqual(contains(archive, 'mercurial_only.txt'), True)
Exemple #14
0
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True))
     st.run_dist(self.clonedir, [],
                 'sdist', ['--formats=zip'],
                 ff=self.type)
     self.failIf(isfile(join(self.clonedir, 'setup.pyc')))
Exemple #15
0
 def testSubversionMetaFile(self):
     st = Setuptools(Process(quiet=True))
     archive = st.run_dist(self.clonedir, [],
                           'sdist', ['--formats=zip'],
                           ff=self.type)
     self.assertEqual(contains(archive, '.svnignore'), False)
Exemple #16
0
 def testSubversionMetaFile(self):
     st = Setuptools(Process(quiet=True))
     # This uses svn to create the manifest.
     archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"], scmtype="svn")
     self.assertEqual(contains(archive, ".svnignore"), False)
Exemple #17
0
 def testSubversionSdistPy(self):
     st = Setuptools(Process(quiet=True))
     # This uses svn to create the manifest.
     archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"])
     self.assertEqual(contains(archive, "subversion_only.py"), True)
Exemple #18
0
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True))
     self.clone()
     st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"], scmtype="git")
     self.failIf(isfile(join(self.clonedir, "setup.pyc")))
Exemple #19
0
 def testGitMetaFile(self):
     st = Setuptools(Process(quiet=True))
     self.clone()
     # This uses git to create the manifest.
     archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"], scmtype="git")
     self.assertEqual(contains(archive, ".gitignore"), False)
 def testMercurialSdistTxt(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='hg')
     self.assertEqual(contains(archive, 'mercurial_only.txt'), True)
Exemple #21
0
 def testGitSdistC(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [],
                           'sdist', ['--formats=zip'],
                           ff='git')
     self.assertEqual(contains(archive, 'git_only.c'), True)
Exemple #22
0
 def testMercurialSdistPy(self):
     st = Setuptools(Process(quiet=True))
     self.clone()
     # This uses hg to create the manifest.
     archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"])
     self.assertEqual(contains(archive, "mercurial_only.py"), True)
Exemple #23
0
 def testGitMetaFile(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [],
                           'sdist', ['--formats=zip'],
                           ff='git')
     self.assertEqual(contains(archive, '.gitignore'), False)
 def testManifestMetaFile(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='none')
     self.assertEqual(contains(archive, '.gitignore'), False)
Exemple #25
0
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     st.run_dist(self.packagedir, [], 'sdist', ['--formats=zip'], ff='git')
     self.failIf(isfile(join(self.packagedir, 'setup.pyc')))
 def testSubversionSdistC(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], ff='svn')
     self.assertEqual(contains(archive, 'subversion_only.c'), True)
Exemple #27
0
def get_env():
    return Setuptools().get_env()
Exemple #28
0
 def testMercurialSdistPy(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     self.clone()
     # This uses hg to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'mercurial_only.py'), True)
Exemple #29
0
 def testSubversionMetaFile(self):
     st = Setuptools(Process(quiet=True))
     # This uses svn to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], scmtype='svn')
     self.assertEqual(contains(archive, '.svnignore'), False)
Exemple #30
0
 def testGitMetaFile(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     self.clone()
     # This uses git to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], scmtype='git')
     self.assertEqual(contains(archive, '.gitignore'), False)
 def testSubversionSdistTxt(self):
     st = Setuptools(Process(quiet=True))
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], ff=self.type)
     self.assertEqual(contains(archive, 'subversion_only.txt'), True)
Exemple #32
0
 def testSubversionSdistTxt(self):
     st = Setuptools(Process(quiet=True))
     # This uses svn to create the manifest.
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'subversion_only.txt'), True)
 def testSubversionMetaFile(self):
     st = Setuptools(Process(quiet=True, env=get_env()))
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], ff='svn')
     self.assertEqual(contains(archive, '.svnignore'), False)
Exemple #34
0
 def testSubversionSdistC(self):
     st = Setuptools(Process(quiet=True))
     archive = st.run_dist(self.clonedir, [],
                           'sdist', ['--formats=zip'],
                           ff=self.type)
     self.assertEqual(contains(archive, 'subversion_only.c'), True)
Exemple #35
0
 def testGitSdistTxt(self):
     st = Setuptools(Process(quiet=True))
     self.clone()
     # This uses git to create the manifest.
     archive = st.run_dist(self.clonedir, [], "sdist", ["--formats=zip"])
     self.assertEqual(contains(archive, "git_only.txt"), True)
Exemple #36
0
 def testDefaultSdistPy(self):
     st = Setuptools(Process(quiet=True))
     self.destroy(self.clonedir)
     # Use the default file-finder to create the manifest
     archive = st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'])
     self.assertEqual(contains(archive, 'subversion_only.py'), True)
 def testRemoveSetupPyc(self):
     st = Setuptools(Process(quiet=True))
     st.run_dist(self.clonedir, [], 'sdist', ['--formats=zip'], ff=self.type)
     self.assertFalse(isfile(join(self.clonedir, 'setup.pyc')))