FieldMappingsDisplayContext { public String getSelectedIndexName() { return _selectedIndexName; }  Map<String, Object> getData(); List<FieldMappingIndexDisplayContext> getFieldMappingIndexDisplayContexts(); String getFieldMappings(); List<String> getIndexNames(); String getSelectedIndexName(); void setData(Map<String, Object> data); void setFieldMappingIndexDisplayContexts(
		List<FieldMappingIndexDisplayContext>
			fieldMappingIndexDisplayContexts); void setFieldMappings(String fieldMappings); void setIndexNames(List<String> indexNames); void setSelectedIndexName(String selectedIndexName);  }
@Test public void testGetSelectedIndexName() { FieldMappingsDisplayBuilder fieldMappingsDisplayBuilder = new FieldMappingsDisplayBuilder(http); fieldMappingsDisplayBuilder.setCurrentURL("/"); fieldMappingsDisplayBuilder.setIndexInformation(indexInformation); fieldMappingsDisplayBuilder.setNamespace("_namespace_"); fieldMappingsDisplayBuilder.setSelectedIndexName("index2"); FieldMappingsDisplayContext fieldMappingsDisplayContext = fieldMappingsDisplayBuilder.build(); Assert.assertEquals( "index2", fieldMappingsDisplayContext.getSelectedIndexName()); List<FieldMappingIndexDisplayContext> fieldMappingIndexDisplayContexts = fieldMappingsDisplayContext.getFieldMappingIndexDisplayContexts(); Assert.assertEquals( fieldMappingIndexDisplayContexts.toString(), 2, fieldMappingIndexDisplayContexts.size()); FieldMappingIndexDisplayContext fieldMappingIndexDisplayContext = fieldMappingIndexDisplayContexts.get(0); Assert.assertEquals( "index1", fieldMappingIndexDisplayContext.getName()); Assert.assertEquals("", fieldMappingIndexDisplayContext.getCssClass()); fieldMappingIndexDisplayContext = fieldMappingIndexDisplayContexts.get( 1); Assert.assertEquals( "index2", fieldMappingIndexDisplayContext.getName()); Assert.assertEquals( "active", fieldMappingIndexDisplayContext.getCssClass()); }