### Question:
JNCryptorFactory { public static List<JNCryptor> getCryptors() { List<JNCryptor> result = new ArrayList<JNCryptor>(supportedVersions.size()); for (Integer version : supportedVersions.keySet()) { result.add(supportedVersions.get(version)); } return result; } private  JNCryptorFactory(); static JNCryptor getCryptorForCiphertext(byte[] ciphertext); static JNCryptor getCryptor(); static JNCryptor getCryptor(int version); static List<JNCryptor> getCryptors();  }### Answer:
@Test public void testGetAllCryptors() throws Exception { List<JNCryptor> cryptors = JNCryptorFactory.getCryptors(); URL url = JNCryptorFactoryTest.class.getResource("/jncryptor-classes.txt"); if (url == null) { fail("Cannot find cryptor class list."); } List<String> classList = FileUtils.readLines(new File(url.getPath())); for (String clazz : classList) { try { Class.forName(clazz); } catch (ClassNotFoundException e) { fail(String.format("Could not find class: %s", clazz)); } } assertEquals(classList.size(), cryptors.size()); for (JNCryptor cryptor : cryptors) { assertTrue(classList.contains(cryptor.getClass().getCanonicalName())); } }