Skip to content

0.9.6

Compare
Choose a tag to compare
@shawnbrown shawnbrown released this 03 Jun 04:25
· 417 commits to master since this release
  • Changed acceptance API to make it both less verbose and
    more expressive:

    • Consolidated specific-instance and class-based acceptances
      into a single interface.

    • Added a new accepted.tolerance() method that subsumes the
      behavior of accepted.deviation() by supporting Missing and
      Extra quantities in addition to Deviation objects.

    • Deprecated old methods:

      Old SyntaxNew Syntax
      accepted.specific(...)accepted(...)
      accepted.missing()accepted(Missing)
      accepted.extra()accepted(Extra)
      NO EQUIVALENTaccepted(CustomDifferenceClass)
      accepted.deviation(...)accepted.tolerance(...)
      accepted.limit(...)accepted.count(...)
      NO EQUIVALENTaccepted.count(..., scope='group')

      Other methods--accepted.args(), accepted.keys(), etc.--remain
      unchanged.

  • Changed validation to generate Deviation objects for a broader
    definition of quantitative values (like datetime objects)--not
    just for subclasses of numbers.Number.

  • Changed handling for pandas.Series objects to treat them as
    sequences instead of mappings.

  • Added handling for DBAPI2 cursor objects to automatically
    unwrap single-value rows.

  • Removed acceptance classes from datatest namespace--these were
    inadvertently added in a previous version but were never part
    of the documented API. They can still be referenced via the
    acceptances module:

    from datatest.acceptances import ...