Remove dependence on sync mode from textclassifier tests

Some tests (e.g. ModelDownloaderIntegrationTest) required DeviceConfig
syncing to be enabled. This is fixed using DeviceConfigStateHelper to
enable/revert syncing when necessary, and allows syncs to be disabled by
default during testing to ensure deterministic platform flags.

Bug: 283536230
Bug: 289277724
Test: atest TextClassifierServiceTest
Test: atest TCSModelDownloaderIntegrationTest
Change-Id: Ia04b5267e9394703c176c3f0935563ed6ee45f91
2 files changed