Replace SetFlagsRule with CheckFlagsRule.
SetFlagsRule is intended for unit tests of completely isolated
unit test methods; while ProxyManagerTest does use mocking in order
to keep its execution environment simpler & assert that certain mocked
methods are executed, it is still an executed as an integration test
that depends on the running state of the device and interacts with
other classes on the device.
CheckFlagsRule is better suited for testing non-isolated methods
because it uses the default value of all flags on the device (it
doesn't change any flags) and instead skips irrelevant tests if
a flag is required to be enabled or disable for a given test.
Bug: 286587811
Test: atest ProxyManagerTest, both with flag disabled & enabled
Change-Id: I615af25b71c5696f11e7901b12948a8fc0d7f79b
1 file changed