@Test
  public void testPopulateJobConfig() throws Exception {
    IJobConfiguration job = IJobConfiguration.build(makeJob());
    SanitizedConfiguration sanitized =
        SanitizedConfiguration.fromUnsanitized(TaskTestUtil.CONFIGURATION_MANAGER, job);
    control.replay();

    Response response = assertOkResponse(thrift.populateJobConfig(job.newBuilder()));
    assertEquals(
        Result.populateJobResult(
            new PopulateJobResult(sanitized.getJobConfig().getTaskConfig().newBuilder())),
        response.getResult());
  }
Exemple #2
0
 static Response jobSummaryResponse(Set<JobSummary> jobSummaries) {
   return okResponse(Result.jobSummaryResult(new JobSummaryResult().setSummaries(jobSummaries)));
 }