Пример #1
0
  public static void assertEquals(ECFilterSpec expected, ECFilterSpec actual) {

    if (expected == null || actual == null) {
      if (expected == null && actual == null) {
        return;
      } else {
        throw new AssertionFailedError();
      }
    }
    assertEquals(expected.getExcludePatterns(), actual.getExcludePatterns());
    assertEquals(expected.getIncludePatterns(), actual.getIncludePatterns());
    assertEquals(expected.getAny(), actual.getAny());
    assertEquals(expected.getExtension(), actual.getExtension());
  }
Пример #2
0
  public static ECFilterSpec createECFilterSpec() {

    // create spec
    ECFilterSpec spec = new ECFilterSpec();

    // set include patterns
    spec.setIncludePatterns(new ECFilterSpec.IncludePatterns());
    spec.getIncludePatterns().getIncludePattern().addAll(INCLUDE_PATTERNS);

    // set exclude patterns
    spec.setExcludePatterns(new ECFilterSpec.ExcludePatterns());
    spec.getExcludePatterns().getExcludePattern().addAll(EXCLUDE_PATTERNS);

    return spec;
  }