Skip to content

Command generation tests should assert against generated scripts rather than intermediate commands #14

@bartread

Description

@bartread

Relates to findings from #12 and #13, where an existing command generation test - OneToOneRelationshipCommandGenerationTests.insert_with_fk_on_child_and_special_data_in_child_inserts_in_parent_and_updates_child - where test failed to catch problem described in #13.

Fundamentally I don't think asserting against operations and commands is robust enough. What matters is the output at the end of the process - i.e., the scripts that SimpleSave generates, and ultimately the resultant state of the database.

I think a good intermediate step for now is to begin transitioning tests to assert on scripts rather than commands. We can then later implement some localdb tests to check database state. (At the moment we're relying on PaymentSense internal tests for this, which we obviously can't use here.)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions