### Question:
KubernetesLauncher implements BaseLauncher { protected void logAgendaMetadata(Agenda agenda) { String owner = "agenda owner not visible"; owner = agenda != null && agenda.getCustomerId() != null ? agenda.getCustomerId() : owner; String agendId = "agendaId not visible"; agendId = agenda != null && agenda.getId() != null ? agenda.getId() : agendId; logger.info(String.format(PULLER_AGENDA_METADATA_PATTERN, AGENDA_TYPE, owner, agendId)); } KubernetesLauncher(KubeConfig kubeConfig, PodConfig podConfig, ExecutionConfig executionConfig, PullerLaunchDataWrapper launchDataWrapper);  KubernetesLauncher(KubeConfig kubeConfig, PodConfig podConfig, ExecutionConfig executionConfig, PullerLaunchDataWrapper launchDataWrapper,
        PodPushClientFactory<CpuRequestModulator> podPushClientFactory, PodFollowerFactory<PodPushClient> podFollowerFactory); void setFollower(PodFollower<PodPushClient> follower); void setKubeConfig(KubeConfig kubeConfig); void setPodConfig(PodConfig podConfig); void setExecutionConfig(ExecutionConfig executionConfig); @Override void execute(Agenda agenda, AgendaProgress agendaProgress);  }### Answer:
@Test public void testLog() { CaptureLogger captureLogger = new CaptureLogger("testLogger"); kubernetesLauncher.setLogger(captureLogger); Agenda agenda = new Agenda(); String customerId = "testCustomerId"; agenda.setCustomerId(customerId); String agendaId = "testAgendaId"; agenda.setId(agendaId); kubernetesLauncher.logAgendaMetadata(agenda); String capturedLog = captureLogger.getInfo(); SoftAssertions.assertSoftly(softly -> { softly.assertThat(capturedLog).contains(customerId); softly.assertThat(capturedLog).contains(agendaId); }); }
@Test public void testLogNullAgenda() { CaptureLogger captureLogger = new CaptureLogger("testLogger"); kubernetesLauncher.setLogger(captureLogger); kubernetesLauncher.logAgendaMetadata(null); String capturedLog = captureLogger.getInfo(); SoftAssertions.assertSoftly(softly -> { softly.assertThat(capturedLog).contains("agenda owner not visible"); softly.assertThat(capturedLog).contains("agendaId not visible"); }); }
@Test public void testLogNullAgendaFields() { CaptureLogger captureLogger = new CaptureLogger("testLogger"); kubernetesLauncher.setLogger(captureLogger); kubernetesLauncher.logAgendaMetadata(new Agenda()); String capturedLog = captureLogger.getInfo(); SoftAssertions.assertSoftly(softly -> { softly.assertThat(capturedLog).contains("agenda owner not visible"); softly.assertThat(capturedLog).contains("agendaId not visible"); }); }