Recently, I came across advice suggesting we should "Strive for unchanging tests" in the book 'Engineering at Google'. This resonated with your discussion about controllability. I believe the aim of creating code that is resilient to change, or can be easily modified when necessary, is not exclusive to tests but extends to any piece of c…
Recently, I came across advice suggesting we should "Strive for unchanging tests" in the book 'Engineering at Google'. This resonated with your discussion about controllability. I believe the aim of creating code that is resilient to change, or can be easily modified when necessary, is not exclusive to tests but extends to any piece of code we produce.
In your view, how closely does this idea of striving for unchanging code align with the controllability you're discussing? Do you see them as two facets of the same principle?
From TestDesiderata.com, tests should be insensitive to structural changes but sensitive to behavior changes. This is more of a design problem than a testing problem.
Controllability for me is about making the state of a computation explicit. If my code has an if statement that depends, implicitly, on data stored in another service, then I can't easily control the code. If at some level of the code that data is passed explicitly as a parameter to a function, then I can control that part of the computation.
I'm not sure I answered your question. Please ask more.
Thanks for your insights, Kent. The distinction you draw between unchanging tests and controllability is illuminating, and I appreciate the nuanced approach of the test Desiderata as compared to simply stating "strive for unchanging tests."
Your perspective on controllability brings to mind the interplay between data and interface. It seems to me that if a data structure already adequately abstracts the underlying dependencies, it could serve as the ideal point of balance between abstraction and concreteness, thereby enhancing controllability. However, in the absence of such a data structure, relying on an interface might be the necessary course of action.
In your experience, what are some guiding principles or considerations when deciding between data and interface for enhancing controllability?
Recently, I came across advice suggesting we should "Strive for unchanging tests" in the book 'Engineering at Google'. This resonated with your discussion about controllability. I believe the aim of creating code that is resilient to change, or can be easily modified when necessary, is not exclusive to tests but extends to any piece of code we produce.
In your view, how closely does this idea of striving for unchanging code align with the controllability you're discussing? Do you see them as two facets of the same principle?
From TestDesiderata.com, tests should be insensitive to structural changes but sensitive to behavior changes. This is more of a design problem than a testing problem.
Controllability for me is about making the state of a computation explicit. If my code has an if statement that depends, implicitly, on data stored in another service, then I can't easily control the code. If at some level of the code that data is passed explicitly as a parameter to a function, then I can control that part of the computation.
I'm not sure I answered your question. Please ask more.
Thanks for your insights, Kent. The distinction you draw between unchanging tests and controllability is illuminating, and I appreciate the nuanced approach of the test Desiderata as compared to simply stating "strive for unchanging tests."
Your perspective on controllability brings to mind the interplay between data and interface. It seems to me that if a data structure already adequately abstracts the underlying dependencies, it could serve as the ideal point of balance between abstraction and concreteness, thereby enhancing controllability. However, in the absence of such a data structure, relying on an interface might be the necessary course of action.
In your experience, what are some guiding principles or considerations when deciding between data and interface for enhancing controllability?