### Question:
FrameworkJobSchedulerService extends JobService { @Override public boolean onStopJob(JobParameters params) { FrameworkScheduler scheduler = getScheduler(); if (scheduler != null) { return scheduler.onStopJob(params); } JqLog.e("FrameworkJobSchedulerService has been stopped but it does not have a" + " scheduler. You must initialize JobManager before the service is created."); return false; }  @SuppressWarnings("unused") static FrameworkScheduler createSchedulerFor(
            @SuppressWarnings("UnusedParameters") Context appContext,
            Class<? extends FrameworkJobSchedulerService> klass); @Override void onCreate(); @Override void onDestroy(); @Override boolean onStartJob(JobParameters params); @Override boolean onStopJob(JobParameters params);  }### Answer:
@Test public void onStopJob() { JobParameters params = mock(JobParameters.class); service.onStopJob(params); verify(mockScheduler).onStopJob(params); }