MCPcopy Create free account
hub / github.com/boostorg/histogram / test

Method test

test/python_suite_test.py:617–627  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

615 self.assertEqual(h, h2)
616
617 def test(self):
618 axes = (regular(10, 0, 1), integer(0, 1))
619 h = histogram(*axes)
620 for i, a in enumerate(axes):
621 self.assertEqual(h.axis(i), a)
622 with self.assertRaises(IndexError):
623 h.axis(2)
624 self.assertEqual(h.axis(-1), axes[-1])
625 self.assertEqual(h.axis(-2), axes[-2])
626 with self.assertRaises(IndexError):
627 h.axis(-3)
628
629 def test_overflow(self):
630 h = histogram(*[regular(1, 0, 1) for i in range(50)])

Callers

nothing calls this directly

Calls 4

regularClass · 0.90
integerClass · 0.90
axisMethod · 0.80
histogramClass · 0.50

Tested by

no test coverage detected