Skip to content

Remove testing utilities from production code #175

Description

@petervlk

Function docker-postgres! defined in namespace framework.db.core is only being used in test namespaces, whether we look at the framework codebase, its examples or the Frankie project. I doubt that I will ever be used in any production environment and for this reason I propose that it should be removed from production code.

It also invites developers to expand configuration of their projects in a manner that I personally don't consider correct.

I agree that the function is valuable for testing purposes, but if we insist on keeping and maintaining it, we should move it to a separate project which can be later used strictly as a test dependency and not to be part of a production code.

Activity

  1. soulflyer commented on Jun 24, 2022

    @soulflyer
    Contributor

    Move to a separate namespace that is not included in the prod uberjar.

  2. petervlk commented on Jul 14, 2022

    @petervlk
    Author

    Move to a separate namespace that is not included in the prod uberjar.

    this is a breaking change, because some some clients might be using this function. I am fine with this, since docker-postgres! is just destructuring xiana cinfig and simply building testcontainer docker instance. maybe we can move it into examples, so anyone who will need it can copy paste it

  3. petervlk commented on Jul 14, 2022

    @petervlk
    Author

    but it is necessary to remove it if we dont want to force clients to depend on testcontiners in their production artifacts.

  4. g-krisztian commented on Sep 21, 2022

    @g-krisztian
    Collaborator

    New PR #233

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