sourcedb test
This commit is contained in:
@@ -23,6 +23,12 @@
|
||||
into argv[] style arrays
|
||||
</Description>
|
||||
<Archive sha1sum="66f3c77b87a160951b180447f4a6dce68ad2f71b" type="targz">ftp://ftp.pardus.org.tr/pub/pisi/source/popt-1.7.tar.gz</Archive>
|
||||
<Patches>
|
||||
<Patch compressionType="gz" level="1">popt-1.7-uclibc.patch.gz</Patch>
|
||||
</Patches>
|
||||
<BuildDependencies>
|
||||
<Dependency versionFrom="1.8"> make </Dependency>
|
||||
</BuildDependencies>
|
||||
</Source>
|
||||
|
||||
<Package>
|
||||
@@ -42,6 +48,26 @@
|
||||
</Files>
|
||||
</Package>
|
||||
|
||||
<Package>
|
||||
<Name>popt-libs</Name>
|
||||
<Summary xml:lang="en">Command line option parsing library</Summary>
|
||||
<Summary xml:lang="tr">Komut satırı seçenekleri işleme kütüphanesi</Summary>
|
||||
<RuntimeDependencies>
|
||||
<Dependency>gettext</Dependency>
|
||||
</RuntimeDependencies>
|
||||
<Description>library files for popt</Description>
|
||||
<Files>
|
||||
<Path fileType="sharedLib">/usr/lib</Path>
|
||||
<Path fileType="doc">/usr/share/doc</Path>
|
||||
<Path fileType="doc">/usr/share/man</Path>
|
||||
<Path fileType="localedata">/usr/share/locale</Path>
|
||||
<Path fileType="header">/usr/include/popt.h</Path>
|
||||
</Files>
|
||||
<AdditionalFiles>
|
||||
<AdditionalFile owner="root" permission="0755" target="/etc/init.d/acpid">acpid.rc6</AdditionalFile>
|
||||
</AdditionalFiles>
|
||||
</Package>
|
||||
|
||||
<History>
|
||||
<Update release="1">
|
||||
<Date>2005-06-14</Date>
|
||||
|
||||
@@ -25,7 +25,7 @@ class SpecFileNewTestCase(unittest.TestCase):
|
||||
|
||||
self.assertEqual(self.spec.source.version, "1.7")
|
||||
|
||||
self.assertEqual(self.spec.source.release, "3")
|
||||
self.assertEqual(self.spec.source.release, "1")
|
||||
|
||||
self.assertEqual(self.spec.source.archive.sha1sum,
|
||||
"66f3c77b87a160951b180447f4a6dce68ad2f71b")
|
||||
@@ -37,8 +37,8 @@ class SpecFileNewTestCase(unittest.TestCase):
|
||||
self.assertEqual(patch.compressionType, "gz")
|
||||
|
||||
packages = self.spec.packages
|
||||
self.assertEqual(len(packages), 1)
|
||||
package = packages[0] # get the first and the only package
|
||||
self.assertEqual(len(packages), 2)
|
||||
package = packages[1]
|
||||
self.assertEqual(package.name, "popt-libs")
|
||||
|
||||
# search for a path in package.paths
|
||||
@@ -49,22 +49,22 @@ class SpecFileNewTestCase(unittest.TestCase):
|
||||
|
||||
def testIsAPartOf(self):
|
||||
# test existence in Source
|
||||
if not "library:util:optparser" in self.spec.source.isA:
|
||||
if not "app:console" in self.spec.source.isA:
|
||||
self.fail("Failed to match IsA in Source")
|
||||
if not isinstance(self.spec.source.isA, list):
|
||||
self.fail("source.isA is not a list, but it must be...")
|
||||
|
||||
if "rpm:archive" != self.spec.source.partOf:
|
||||
|
||||
if "system.base" != self.spec.source.partOf:
|
||||
self.fail("Failed to match PartOf in Source")
|
||||
|
||||
# test existence in Package
|
||||
pkg = self.spec.packages[0]
|
||||
if not "library:util:optparser" in pkg.isA:
|
||||
if not "app:console" in pkg.isA:
|
||||
self.fail("Failed to match IsA in Package")
|
||||
if not isinstance(pkg.isA, list):
|
||||
self.fail("source.isA is not a list, but it must be...")
|
||||
|
||||
if "rpm:archive" != pkg.partOf:
|
||||
if "system.base" != pkg.partOf:
|
||||
self.fail("Failed to match PartOf in Package")
|
||||
|
||||
def testVerify(self):
|
||||
|
||||
Reference in New Issue
Block a user