'Determine the supported package management systems present on the
system. If more than one package management system installed, try
to find the best supported system.'

def get_package_management(self):

    list_supported = []
    for high_level_pm in SUPPORTED_PACKAGE_MANAGERS:
        try:
            os_dep.command(high_level_pm)
            list_supported.append(high_level_pm)
        except ValueError:
            pass
    pm_supported = None
    if (len(list_supported) == 0):
        pm_supported = None
    if (len(list_supported) == 1):
        pm_supported = list_supported[0]
    elif (len(list_supported) > 1):
        if (('apt-get' in list_supported) and (self.distro in ('debian', 'ubuntu'))):
            pm_supported = 'apt-get'
        elif (('yum' in list_supported) and (self.distro in ('redhat', 'fedora'))):
            pm_supported = 'yum'
        else:
            pm_supported = list_supported[0]
    return pm_supported
