Java Code Examples for org.hamcrest.Description#appendList()

The following examples show how to use org.hamcrest.Description#appendList() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ConjunctionMatcher.java    From hamcrest-compose with Apache License 2.0 5 votes vote down vote up
@Override
public void describeTo(Description description)
{
	if (matchers.isEmpty())
	{
		description.appendText(compositeDescription != null ? compositeDescription : "anything");
	}
	else
	{
		String start = (compositeDescription != null) ? compositeDescription + " " : "";
	
		description.appendList(start, SEPARATOR, "", matchers);
	}
}
 
Example 2
Source File: MatchersPrinter.java    From astor with GNU General Public License v2.0 4 votes vote down vote up
public String getArgumentsLine(List<Matcher> matchers, PrintSettings printSettings) {
    Description result = new StringDescription();
    result.appendList("(", ", ", ");", applyPrintSettings(matchers, printSettings));
    return result.toString();
}
 
Example 3
Source File: MatchersPrinter.java    From astor with GNU General Public License v2.0 4 votes vote down vote up
public String getArgumentsBlock(List<Matcher> matchers, PrintSettings printSettings) {
    Description result = new StringDescription();
    result.appendList("(\n    ", ",\n    ", "\n);", applyPrintSettings(matchers, printSettings));
    return result.toString();
}
 
Example 4
Source File: MatchersPrinter.java    From astor with GNU General Public License v2.0 4 votes vote down vote up
public String getArgumentsLine(List<Matcher> matchers, PrintSettings printSettings) {
    Description result = new StringDescription();
    result.appendList("(", ", ", ");", applyPrintSettings(matchers, printSettings));
    return result.toString();
}
 
Example 5
Source File: MatchersPrinter.java    From astor with GNU General Public License v2.0 4 votes vote down vote up
public String getArgumentsBlock(List<Matcher> matchers, PrintSettings printSettings) {
    Description result = new StringDescription();
    result.appendList("(\n    ", ",\n    ", "\n);", applyPrintSettings(matchers, printSettings));
    return result.toString();
}
 
Example 6
Source File: AbstractLuceneQueryTest.java    From querqy with Apache License 2.0 4 votes vote down vote up
@Override
public void describeTo(Description description) {
    description.appendText("DMQ: tie=" + tieBreaker + ", boost=" + boost + ", ");
    description.appendList("disjuncts:[", ",\n", "]", Arrays.asList(disjuncts));
}
 
Example 7
Source File: AbstractLuceneQueryTest.java    From querqy with Apache License 2.0 4 votes vote down vote up
@Override
public void describeTo(Description description) {
    description.appendText("BQ: mm=" + mm + ", boost=" + boost + ", ");
    description.appendList("clauses:[", ",\n", "]", Arrays.asList(clauses));
}
 
Example 8
Source File: QuerqyMatchers.java    From querqy with Apache License 2.0 4 votes vote down vote up
@Override
public void describeTo(Description description) {
   occur.describeTo(description);
   description.appendList("clauses:[", ",\n", "]", Arrays.asList(clauses));
}
 
Example 9
Source File: TableAnswerElementMatchersImpl.java    From batfish with Apache License 2.0 4 votes vote down vote up
@Override
public void describeTo(Description description) {
  description.appendList("A TableAnswerElement with rows matching: [", ",", "]", _rowMatchers);
}
 
Example 10
Source File: IsInstanceOfWith.java    From es6draft with MIT License 4 votes vote down vote up
@Override
public void describeTo(Description description) {
    description.appendList("(", " " + "and" + " ", ")", Arrays.asList(instanceOf, predicate));
}
 
Example 11
Source File: CompositeMatcher.java    From timbuctoo with GNU General Public License v3.0 4 votes vote down vote up
@Override
public void describeTo(Description description) {
  description.appendList("(", " " + "and" + " ", ")", getMatchers());
}