### Question:
SolrQueryResponseWriterFactory { public static String getContentType(String wt) { String contentType = null; if (wt == null || wt.trim().equals("") || wt.equals(XML)) { contentType = "text/xml"; } else if (wt.equals(JSON)) { contentType = "text/json"; } else if (wt.equals(PYTHON)) { contentType = "text/plain"; } else if (wt.equals(RUBY)) { contentType = "text/plain"; } else if (wt.equals(PHP)) { contentType = "text/plain"; } else if (wt.equals(PHPS)) { contentType = "text/plain"; } else if (wt.equals(VELOCITY)) { contentType = "text/html"; } else if (wt.equals(CSV)) { contentType = "text/csv"; } else { contentType = null; } return contentType; }  static QueryResponseWriter generateResponseWriter(String wt); static String getContentType(String wt); static final String XML; static final String JSON; static final String PYTHON; static final String RUBY; static final String PHP; static final String PHPS; static final String VELOCITY; static final String CSV; }### Answer:
@Test public void testGetContentType() throws Exception { String contentType = SolrQueryResponseWriterFactory.getContentType(SolrQueryResponseWriterFactory.XML); assertTrue(contentType.equals("text/xml")); contentType = SolrQueryResponseWriterFactory.getContentType(SolrQueryResponseWriterFactory.JSON); assertTrue(contentType.equals("text/json")); contentType = SolrQueryResponseWriterFactory.getContentType("other"); assertTrue(contentType == null); }