Package org.nasutekds.server.api

Examples of org.nasutekds.server.api.SubtreeSpecification


  public void testMatches16() throws Exception {
    DN dn = DN.decode("dc=foo, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificExclusions { chopBefore:\"dc=foo\" } }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(false, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here


  public void testMatches17() throws Exception {
    DN dn = DN.decode("dc=bar, dc=foo, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificExclusions { chopBefore:\"dc=foo\" } }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(false, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testMatches18() throws Exception {
    DN dn = DN.decode("dc=abc, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificExclusions { chopBefore:\"dc=foo\" } }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(true, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testMatches19() throws Exception {
    DN dn = DN.decode("dc=abc, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificationFilter item:person }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(true, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testMatches20() throws Exception {
    DN dn = DN.decode("dc=abc, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificationFilter item:organization }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(false, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testMatches21() throws Exception {
    DN dn = DN.decode("dc=abc, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificationFilter not:item:person }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(false, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testMatches22() throws Exception {
    DN dn = DN.decode("dc=abc, dc=sun, dc=com");

    String value = "{ base \"dc=sun, dc=com\", "
        + "specificationFilter not:item:organization }";
    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        value);

    assertEquals(true, ss
        .isWithinScope(createEntry(dn, getObjectClasses())));
  }
View Full Code Here

  public void testValueOf1() throws Exception {

    String input = "{}";
    String output = "{ }";

    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        input);
    assertEquals(output, ss.toString());
  }
View Full Code Here

  public void testValueOf2() throws Exception {

    String input = "  {    }    ";
    String output = "{ }";

    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        input);
    assertEquals(output, ss.toString());
  }
View Full Code Here

  public void testValueOf3() throws Exception {

    String input = "{ base \"dc=sun, dc=com\" }";
    String output = "{ base \"dc=sun,dc=com\" }";

    SubtreeSpecification ss = RFC3672SubtreeSpecification.valueOf(rootDN,
        input);
    assertEquals(output, ss.toString());
  }
View Full Code Here

TOP

Related Classes of org.nasutekds.server.api.SubtreeSpecification

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.