def testPythagoreanOptNoParams(self): '''Testing Pythagorean without optimization and missing parameters...''' pyth = Pythagoreans.Pythagorean(self.testdict) self.assertRaises(TypeError, pyth.calculatePythagorean, optimize=False)
def testPythagenportFONoOptPrediction(self): '''Testing PythagenportFO with known predictions...''' pyth = Pythagoreans.PythagenportFO(self.testdict) pyth.calculatePythagorean(optimize=False, staticParams=[1.5]) self.assertEqual(pyth.prediction, self.knownPredictions['PythagenportFO'])
def testPythagenpatNoOptPower(self): '''Testing Pythagenpat with known powers...''' pyth = Pythagoreans.Pythagenpat(self.testdict) pyth.calculatePythagorean(optimize=False, staticParams=[0.287]) self.assertEqual(pyth.power, self.knownPowers['Pythagenpat'])
def testPythagoreanNoOptPrediction(self): '''Testing PythagoreanExpectation with known predictions...''' pyth = Pythagoreans.PythagoreanExpectation(self.testdict) pyth.calculatePythagorean(optimize=False, staticParams=[2.63]) self.assertEqual(pyth.prediction, self.knownPredictions['Pythagorean'])