public class PackageManagerTest extends BaseTestCaseWithUser
user
Constructor and Description |
---|
PackageManagerTest() |
Modifier and Type | Method and Description |
---|---|
static void |
addKickstartPackageToChannel(java.lang.String packageName,
Channel channel)
Add a kickstart package with the given name to the given channel.
|
static Package |
addPackageToChannel(java.lang.String packageName,
Channel c)
Create a package with the given name and add it to the given channel.
|
static Package |
addPackageToSystemAndChannel(java.lang.String packageName,
Server s,
Channel c)
Add a new Package to the specified Channel and associate the system
with it.
|
static Package |
addUp2dateToSystemAndChannel(User userIn,
Server s,
java.lang.String version,
Channel c)
Add the up2date package to a system and a channel.
|
static void |
associateSystemToPackage(Server srvr,
Package p)
This method inserts a record into the rhnServerPackage mapping
table to associate a given Server with a particular Package.
|
static void |
associateSystemToPackage(Server srvr,
PackageName pn,
PackageEvr pe)
This method inserts a record into the rhnServerPackage mapping
table to associate a given Server with a particular Package.
|
static void |
associateSystemToPackageWithArch(Server srvr,
Package p)
This method inserts a record into the rhnServerPackage mapping
table to associate a given Server with a particular Package.
|
protected SimpleContentHandler |
getTemporaryHandler(java.io.OutputStream st) |
void |
testCreateLotsofPackagesInChannel() |
void |
testDeletePackages() |
void |
testGetServerNeededUpdatePackageByName() |
void |
testGuestimateChannelInvalidPackage() |
void |
testGuestimateHandlesNullArchId() |
void |
testGuestimateInvalidPackage() |
void |
testListOrphanPackages() |
void |
testLookupCustomPackagesForChannel() |
void |
testLookupPackageForChannelFromChannel() |
void |
testPackageIdsInSet() |
void |
testPackageNameOverview() |
void |
testPossiblePackagesForPushingIntoChannel() |
void |
testRepodata() |
void |
testSystemAvailablePackages() |
void |
testSystemPackageList() |
void |
testUpgradable() |
void |
testUpgradablePackagesFromServerSet() |
void |
testVerCmp() |
commitHappened, setUp, tearDown
assertContains, assertContains, assertContains, assertNotBefore, assertNotBefore, assertNotEmpty, assertNotEmpty, assertPropertyEquals, clearSession, commitAndCloseSession, createDirIfNotExists, disableLocalizationServiceLogging, enableLocalizationServiceLogging, flushAndEvict, getNow, reload, reload
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, runTest, setName, toString
public void testSystemPackageList() throws java.lang.Exception
java.lang.Exception
public void testGuestimateChannelInvalidPackage()
public void testGuestimateHandlesNullArchId() throws java.lang.Exception
java.lang.Exception
public void testGuestimateInvalidPackage() throws java.lang.Exception
java.lang.Exception
public void testUpgradable() throws java.lang.Exception
java.lang.Exception
public void testSystemAvailablePackages() throws java.lang.Exception
java.lang.Exception
public static void associateSystemToPackage(Server srvr, PackageName pn, PackageEvr pe)
srvr
- Server to associate with the packagespn
- The package name to associatepe
- The package evr (version and release).public static void associateSystemToPackage(Server srvr, Package p)
srvr
- Server to associate with the packagesp
- The packagepublic static void associateSystemToPackageWithArch(Server srvr, Package p)
srvr
- Server to associate with the packagesp
- The packagepublic static Package addPackageToSystemAndChannel(java.lang.String packageName, Server s, Channel c) throws java.lang.Exception
packageName
- the name of the package to adds
- the system to associate with the packagec
- The channel to which to add the packagejava.lang.Exception
- something bad happenedpublic static Package addPackageToChannel(java.lang.String packageName, Channel c) throws java.lang.Exception
packageName
- The name of the package to create.c
- The channel to which to add the packagejava.lang.Exception
- something bad happenedpublic void testCreateLotsofPackagesInChannel() throws java.lang.Exception
java.lang.Exception
public void testPossiblePackagesForPushingIntoChannel() throws java.lang.Exception
java.lang.Exception
public void testGetServerNeededUpdatePackageByName() throws java.lang.Exception
java.lang.Exception
public void testPackageIdsInSet() throws java.lang.Exception
java.lang.Exception
public void testVerCmp()
public static Package addUp2dateToSystemAndChannel(User userIn, Server s, java.lang.String version, Channel c) throws java.lang.Exception
userIn
- the users
- the systemversion
- the versionc
- the channeljava.lang.Exception
- something bad happenedpublic static void addKickstartPackageToChannel(java.lang.String packageName, Channel channel) throws java.lang.Exception
packageName
- the name of the package to addchannel
- the channel to add the package tojava.lang.Exception
- something bad happenedpublic void testPackageNameOverview()
public void testLookupPackageForChannelFromChannel() throws java.lang.Exception
java.lang.Exception
public void testLookupCustomPackagesForChannel() throws java.lang.Exception
java.lang.Exception
public void testListOrphanPackages() throws java.lang.Exception
java.lang.Exception
public void testUpgradablePackagesFromServerSet() throws java.lang.Exception
java.lang.Exception
public void testDeletePackages() throws java.lang.Exception
java.lang.Exception
protected SimpleContentHandler getTemporaryHandler(java.io.OutputStream st)
public void testRepodata() throws java.lang.Exception
java.lang.Exception