TestUtils
(flutter/packages) should be deleted/tests refactored
#146457
Labels
c: tech-debt
Technical debt, code quality, testing, etc.
p: camera
The camera plugin
package
flutter/packages repository. See also p: labels.
team-android
Owned by Android platform team
The
camera_android
plugin makes use of aTestUtils
class with the following behavior:This is ... not a good pattern. If the field needs to be made public, it should be made public (or package-private) and
@VisibleForTesting
used. That pattern itself should be kept to a minimum, and instead the APIs should have good inherent testability/make use of patterns like dependency injection.This is blocking my work on flutter/packages#6461, and while I could work around it, I'd be spending a reasonable amount of time working around a bad pattern. If @reidbaker and team are on board, I'd rather spend my time helping you all delete this pattern.
The text was updated successfully, but these errors were encountered: