[Safety Labels] Schedule periodic job on custom intent action
Currently, the SafetyLabelChangesJobService schedules its periodic job upon receiving ACTION_BOOT_COMPLETED. But, we can't simulate this in a test. So, create a new action,SET_UP_SAFETY_LABEL_CHANGES_JOB which we can invoke in a test, and respond to it by scheduling the periodic job. (Also, onStopJob should check for jobid before cancelling main job.) Test: atest SafetyLabelChangesJobServiceTest SafetyLabelChangesJobServiceTest Bug: 261663926 Change-Id: I341dae738d57f765488ce6308fab6a705c0cc24f
Loading
Please register or sign in to comment