Thing is, the regex could fail while the composition did not eg if we
change the message.
Le 6 nov. 2013 19:36, "Glenn Renfro" <notifications@github.com> a écrit :

> In
> spring-xd-shell/src/test/java/org/springframework/xd/shell/command/ComposedTemplate.java:
>
> > +	private final JLineShellComponent shell;
> > +
> > +	public ComposedTemplate(JLineShellComponent shell) {
> > +		this.shell = shell;
> > +	}
> > +
> > +	/**
> > +	 * Remembers created modules, in the form <type>:<name>.
> > +	 */
> > +	private List<String> modules = new ArrayList<>();
> > +
> > +	public String newModule(String name, String definition) {
> > +		CommandResult result = shell.executeCommand(String.format("module compose %s --definition \"%s\"", name,
> > +				definition));
> > +		Matcher matcher = SUCCESS_PATTERN.matcher((CharSequence) result.getResult());
> > +		assertTrue("Module composition apparently failed: " + result.getResult(), matcher.matches());
>
> Nitpicky, but we should just say "Module Composition Failed"
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/spring-projects/spring-xd/pull/389/files#r7473178>
> .
>