How to refactor tightly coupled classes?

后端 未结 6 1078
天命终不由人
天命终不由人 2021-02-10 02:35

I\'m trying to refactor a big tightly coupled application and trying to make it more maintainable and flexible.

I\'ve got many unit tests, so I\'m hoping to refactor ste

6条回答
  •  旧时难觅i
    2021-02-10 02:54

    Thanks for all answers, After struggling with so many different ways I found that the best thing to do was creating interfaces for everything. This allowed me to change the design freely and I only break the build for a day (a day because the project was big and I need to fix so many references and unit tests + some refactoring).

    After day extracting and fixing all interfaces I can create separate solutions and play with the design freely.

    Basically first move I think should be moving everything to interfaces and then try to get rid of internal dependencies.

提交回复
热议问题