### Question:
MoveMusic implements ProcessLibrary.StringConverter { public static MoveMusic fromArgs(String[] args) { if (args.length < 3) { return null; } boolean useUrls = false; int firstPath; if (args[0].startsWith("--")) { firstPath = 1; if (args[0].equals("--use-urls")) { useUrls = true; } else { return null; } } else { firstPath = 0; } if (args.length - firstPath != 3) { return null; } MoveMusic mm = new MoveMusic(args[firstPath], args[firstPath + 1], args[firstPath + 2]); mm.setUseUrls(useUrls); return mm; } MoveMusic(String libraryFilename, String string, String string2); static MoveMusic fromArgs(String[] args); static void main(String[] args); String convert(String s);  }### Answer:
@Test public void enoughArguments() { assertNull("At least three arguments must be provided", MoveMusic.fromArgs(new String[0])); assertNull("At least three arguments must be provided", MoveMusic.fromArgs(new String[1])); assertNull("At least three arguments must be provided", MoveMusic.fromArgs(new String[2])); }
@Test public void badArguments() { assertNull("A switch is not an acceptable argument", MoveMusic.fromArgs(new String[]{"--use-urls", "a"})); assertNull("Too many arguments is a problem", MoveMusic.fromArgs(new String[]{"a", "b", "c","d"})); assertNull("Too many arguments is a problem", MoveMusic.fromArgs(new String[]{"--use-urls", "a", "b", "c", "d"})); assertNull("An unknown switch is a problem", MoveMusic.fromArgs(new String[]{"--unknown", "a", "b"})); }