Skip to content

Make the test suite more robust #163

@hameerabbasi

Description

@hameerabbasi
Collaborator

I was thinking of moving the tests to a more robust unit test model. It'll take:

  • The dtype, shape of each input array.
  • The function name to test (both sparse and NumPy/SciPy) or callable.
  • Where to place the arguments.
  • Any additional arguments to the function.

It will:

  • Generate the random arrays.
  • Perform the operation on both arrays.
  • Compare/assert.

This way, tests just reduce to "stub classes" instead of repetitions.

cc: @mrocklin

Activity

mrocklin

mrocklin commented on Jun 28, 2018

@mrocklin
Contributor
changed the title [-]Move to a more robust unit testing model[/-] [+]Make the test suite more robust[/+] on Jun 28, 2018
rgommers

rgommers commented on Jun 28, 2018

@rgommers

Sounds like that could be helpful. The one thing to check is designing it in such a way that the tracebacks are still as understandable (exactly which set of arguments is failing)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @rgommers@mrocklin@hameerabbasi

        Issue actions

          Make the test suite more robust · Issue #163 · pydata/sparse