### Question:
CucumberMojo extends AbstractJRubyMojo { String allCucumberArgs() { List<String> allCucumberArgs = new ArrayList<String>(); if (cucumberArgs != null) allCucumberArgs.addAll(cucumberArgs); if (extraCucumberArgs != null) allCucumberArgs.add(extraCucumberArgs); allCucumberArgs.add(features); return Utils.join(allCucumberArgs.toArray(), " "); }  void execute(); CucumberTask cucumber(String args);  }### Answer:
@Test public void shouldAddCucumberArgs() { String cucumberArg = "testArg"; mojo.cucumberArgs = new ArrayList<String>(); mojo.cucumberArgs.add(cucumberArg); assertTrue(mojo.allCucumberArgs().contains(cucumberArg)); }
@Test public void shouldAllowZeroAddCucumberArgs() { mojo.extraCucumberArgs = null; mojo.allCucumberArgs(); }
@Test public void shouldSplitAddCucumberArgsIntoRealCucumberArgs() { mojo.extraCucumberArgs = "arg1 arg2 arg3"; assertEquals("arg1 arg2 arg3 features", mojo.allCucumberArgs()); }