Skip to content

Add tests for how the decommutator handles problematic raw files #77

Open

Description

@namurphy

Background

At present, the primary end-to-end test verifies that the decommutator produces the same output files between the original script and the current CLI tool.

Description

We should also test what happens when the decommutator is run on bad or corrupted raw files, and make sure that the code fails in the way that we intend it too. That includes making sure that it raises the expected exception, and the file exits with an error code.

To test this, we will need example problematic data files.

Implementation

For the exceptions, we can use pytest.raises().

with pytest.raises(ValueError):
    ...
    # if a ValueError has not been raised, this context manager will fail the test

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions