### Question:
TemplateSupportInstructionPackage extends DefaultInstructionPackage { @Override public Set<String> groupNames() { final Boolean sampleData = Boolean.valueOf((String) getProperties().get(EssentialConst.PROP_SAMPLE_DATA)); final String templateName = (String) getProperties().get(EssentialConst.PROP_TEMPLATE_NAME); final String templateGroup = Strings.isNullOrEmpty(templateName) ? "jsp" : templateName; if (sampleData) { return new ImmutableSet.Builder<String>() .add(EssentialConst.INSTRUCTION_GROUP_DEFAULT) .add(EssentialConst.PROP_SAMPLE_DATA) .add(templateGroup).build(); } return new ImmutableSet.Builder<String>() .add(EssentialConst.INSTRUCTION_GROUP_DEFAULT) .add(templateGroup).build(); } TemplateSupportInstructionPackage();  TemplateSupportInstructionPackage(final String path); @Override Set<String> groupNames();  }### Answer:
@Test public void testInstructionPackage() throws Exception { InstructionPackage instructionPackage = new TemplateSupportInstructionPackage(); injector.autowireBean(instructionPackage); final String instructionPath = instructionPackage.getInstructionPath(); assertEquals("Expected default path", instructionPath, EssentialConst.DEFAULT_INSTRUCTIONS_PATH); final Map<String, Object> properties = instructionPackage.getProperties(); assertEquals("Expected empty property set", 0, properties.size()); final Set<String> groupNames = instructionPackage.groupNames(); assertEquals("Expected default group names", EXPECTED, groupNames.size()); final InstructionParser parser = instructionPackage.getInstructionParser(); assertNotNull(parser); final EventBus bus = instructionPackage.getEventBus(); assertNotNull(bus); final Instructions instructions = instructionPackage.getInstructions(); assertEquals("Expected no instructions", null, instructions); }