MCPcopy Index your code
hub / github.com/RustPython/RustPython / testLog10

Method testLog10

Lib/test/test_math.py:1275–1285  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1273 self.assertEqual(actual, expected)
1274
1275 def testLog10(self):
1276 self.assertRaises(TypeError, math.log10)
1277 self.ftest('log10(0.1)', math.log10(0.1), -1)
1278 self.ftest('log10(1)', math.log10(1), 0)
1279 self.ftest('log10(10)', math.log10(10), 1)
1280 self.ftest('log10(10**1000)', math.log10(10**1000), 1000.0)
1281 self.assertRaises(ValueError, math.log10, -1.5)
1282 self.assertRaises(ValueError, math.log10, -10**1000)
1283 self.assertRaises(ValueError, math.log10, NINF)
1284 self.assertEqual(math.log(INF), INF)
1285 self.assertTrue(math.isnan(math.log10(NAN)))
1286
1287 @support.bigmemtest(2**32, memuse=0.2)
1288 def test_log_huge_integer(self, size):

Callers

nothing calls this directly

Calls 6

ftestMethod · 0.95
assertTrueMethod · 0.80
assertRaisesMethod · 0.45
log10Method · 0.45
assertEqualMethod · 0.45
logMethod · 0.45

Tested by

no test coverage detected