tests.test_division module — justbases 0.07 documentation

### Navigation

- index
- modules |
- next |
- previous |
- justbases 0.07 documentation »
- tests »
- tests package »

# tests.test_division module

Test for integer conversions.

class `tests.test_division.` `NatDivisionTestCase`(methodName='runTest')

  Bases: `unittest.case.TestCase`

  Tests for division.

  `testExceptionsDivision`()

    Test division exceptions.

  `testExceptionsUndivision`()

    Test undivision exceptions.

  `testInverses`()

    Test that division and undivision are inverses.

  `testTruncation`()

    Test just truncating division result to some precision.

    Integer parts of truncated and non-truncated are always the same.

    The length of repeating and non-repeating is always less than the precision.

    If precision limit was reached before repeating portion was calculated, then the non-repeating portion has `precision` digits and is a prefix of non-repeating-part + repeating part when precision is not bounded.

  `testUpDown`()

    Test that rounding up and rounding down have the right relationship.

### Navigation

- index
- modules |
- next |
- previous |
- justbases 0.07 documentation »
- tests »
- tests package »