Skip to content

Extract the V1 CSV recipient parsing and test it #41

Description

@gyorgybalazsi

batch::submit_from_csv parses its CSV rows inline, inside the
function. batch::v2::parse_recipients does the same work in a named
function, and only the V2 copy has tests.

So the CSV format rule is written twice, and the tests point at one
copy. A change to the format will edit v2::parse_recipients, because
that is what the tests name, and V1 will keep the old behaviour
silently.

Extract the V1 loop into parse_recipients beside its V2 twin, and
give it the same three tests: a good file, an unparsable amount, and an
empty file.

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

    maintenanceMaintenance, deps, and upgrade work

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions