Package com.google.enterprise.connector.mock

Examples of com.google.enterprise.connector.mock.MockRepositoryEventList


      Assert.assertEquals(0, counter);
    }
  }

  public void testStartTraversal() throws RepositoryException {
    MockRepositoryEventList mrel =
        new MockRepositoryEventList("MockRepositoryEventLog1.txt");
    MockRepository r = new MockRepository(mrel);
    QueryManager qm = new MockJcrQueryManager(r.getStore());
    TraversalManager qtm = new JcrTraversalManager(qm);
    {
      DocumentList documentList = qtm.startTraversal();
View Full Code Here


  private void takeMultiFeed(String expectedXml, String repository,
      final boolean supportsInheritedAcls) throws Exception {
    String gsaExpectedResponse = GsaFeedConnection.SUCCESS_RESPONSE;
    String gsaActualResponse;

    MockRepositoryEventList mrel = new MockRepositoryEventList(repository);
    MockRepository r = new MockRepository(mrel);
    QueryManager qm = new MockJcrQueryManager(r.getStore());
    TraversalManager qtm = new JcrTraversalManager(qm);

    MockFeedConnection feedConnection = new MockFeedConnection() {
View Full Code Here

      final boolean useCompression, final boolean supportsInheritedAcls)
      throws Exception {
    String gsaExpectedResponse = GsaFeedConnection.SUCCESS_RESPONSE;
    String gsaActualResponse;

    MockRepositoryEventList mrel = new MockRepositoryEventList(repository);
    MockRepository r = new MockRepository(mrel);
    QueryManager qm = new MockJcrQueryManager(r.getStore());
    TraversalManager qtm = new JcrTraversalManager(qm);

    MockFeedConnection feedConnection = new MockFeedConnection() {
View Full Code Here

import junit.framework.TestCase;

public class MockJcrAdaptedToSpiTraversalTest extends TestCase {

  public void testTraversal() throws RepositoryLoginException, RepositoryException {
    MockRepositoryEventList mrel =
      new MockRepositoryEventList("MockRepositoryEventLog1.txt");
    MockRepository r = new MockRepository(mrel);
    javax.jcr.Repository jcrRepo = new MockJcrRepository(r);
    Connector repo = new JcrConnector(jcrRepo);
    Session session = repo.login();
    TraversalManager qtm = session.getTraversalManager();
View Full Code Here

    InputStream rawEis = new Base64FilterInputStream(rawIs);

    // Encode the content from the JcrConnector.  This creates a JcrConnector
    // like the Test Connector would and then extracts the document and the
    // content stream property as it is done during traversal.
    MockRepositoryEventList eventList = new MockRepositoryEventList(
        "MockRepositoryEventLogBinaryFile.txt");
    MockRepository mockRepo = new MockRepository(eventList);
    MockJcrRepository mockJcrRepo = new MockJcrRepository(mockRepo);
    JcrConnector jcrConn = new JcrConnector(mockJcrRepo);
    TraversalManager travMgr = jcrConn.login().getTraversalManager();
View Full Code Here

TOP

Related Classes of com.google.enterprise.connector.mock.MockRepositoryEventList

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.