### Question:
JobTriggerMapper extends JobMapper { @Override public void mapEntityOnForm(JobForm.Builder form, JobFormEntity entity) { JobSimpleTriggerEntity simpleTrigger = entity.getSimpleTrigger(); if (simpleTrigger == null) { mCalendarTriggerMapper.mapEntityOnForm(form, entity); } else { Integer recurrenceInterval = simpleTrigger.getRecurrenceInterval(); String recurrenceIntervalUnit = simpleTrigger.getRecurrenceIntervalUnit(); boolean triggerIsSimpleType = (recurrenceInterval != null && recurrenceIntervalUnit != null); if (triggerIsSimpleType) { mSimpleTriggerMapper.mapEntityOnForm(form, entity); } else { mNoneTriggerMapper.mapEntityOnForm(form, entity); } } } JobTriggerMapper(
            JobCalendarTriggerMapper calendarTriggerMapper,
            JobSimpleTriggerMapper simpleTriggerMapper,
            JobNoneTriggerMapper noneTriggerMapper
    ); @Override void mapFormOnEntity(JobForm form, JobFormEntity entity); @Override void mapEntityOnForm(JobForm.Builder form, JobFormEntity entity);  }### Answer:
@Test public void should_map_simple_entity_trigger_to_form() throws Exception { givenEntityFormWithSimpleTrigger(); whenMapsEntityToForm(); verify(mSimpleTriggerMapper).mapEntityOnForm(formBuilder, providedFormEntity); }
@Test public void should_map_calendar_entity_trigger_to_form() throws Exception { givenEntityFormWithCalendarTrigger(); whenMapsEntityToForm(); verify(mCalendarTriggerMapper).mapEntityOnForm(formBuilder, providedFormEntity); }
@Test public void should_map_none_entity_trigger_to_form() throws Exception { givenEntityFormWithNoneTrigger(); whenMapsEntityToForm(); verify(mNoneTriggerMapper).mapEntityOnForm(formBuilder, providedFormEntity); }