def test_worth_combined(self): """ Tests combined worth """ md = MinData(common=1, corrosive=2, base=3, noble=4, rare=5, precious=6, radioactive=7, exotic=8) self.assertAlmostEqual(md.worth(), 9.639, 3)
def test_worth_radioactive(self): """ Tests the worth for radioactive """ md = MinData(radioactive=3) self.assertAlmostEqual(md.worth(), 8.0)
def test_worth_exotic(self): """ Tests the worth for exotic """ md = MinData(exotic=3) self.assertAlmostEqual(md.worth(), 25.0)
def test_worth_rare(self): """ Tests the worth for rare """ md = MinData(rare=3) self.assertAlmostEqual(md.worth(), 5.0)
def test_worth_precious(self): """ Tests the worth for precious """ md = MinData(precious=3) self.assertAlmostEqual(md.worth(), 6.0)
def test_worth_noble(self): """ Tests the worth for noble """ md = MinData(noble=3) self.assertAlmostEqual(md.worth(), 4.0)
def test_worth_base(self): """ Tests the worth for base """ md = MinData(base=3) self.assertAlmostEqual(md.worth(), 3.0)
def test_worth_corrosive(self): """ Tests the worth for corrosive """ md = MinData(corrosive=3) self.assertAlmostEqual(md.worth(), 2.0)
def test_worth_common(self): """ Tests the worth for common """ md = MinData(common=3) self.assertAlmostEqual(md.worth(), 1.0)
def test_worth_empty(self): """ Tests the worth for empty """ md = MinData() self.assertAlmostEqual(md.worth(), 0.0)