def sanityCheck(): logger.subsection("checking to make sure system environment is sane") err = scheck.initialize() if(len(err) > 0): logger.subsection("the following errors resulted from sanity check:") for message in err: logger.subsection(message) logger.subsection("installation cannot continue") return 1 else: logger.subsection("yup, system is sane") return 0
def test_oscheck(self): sanity.osCheck() self.assert_("Unsupported Operating System" not in sanity.errorsList)
def test_netcheck(self): sanity.networkCheck() self.assert_("Hostname is localhost" not in sanity.errorsList)
def test_rubycheck(self): sanity.rubyCheck() self.assert_("Ruby not found" not in sanity.errorsList)
def test_rootcheck(self): sanity.rootCheck() self.assert_("Not run as root" not in sanity.errorsList)