Package org.eclipse.jgit.storage.file

Examples of org.eclipse.jgit.storage.file.FileRepository


   *
   * @throws IOException
   */
  @Test(expected = IllegalArgumentException.class)
  public void getRawContentEmptyRevision() throws IOException {
    BlobUtils.getRawContent(new FileRepository(testRepo), "", "test.txt");
  }
View Full Code Here


   *
   * @throws IOException
   */
  @Test(expected = IllegalArgumentException.class)
  public void getRawContentNullPath() throws IOException {
    BlobUtils.getRawContent(new FileRepository(testRepo),
        ObjectId.zeroId(), null);
  }
View Full Code Here

   *
   * @throws IOException
   */
  @Test(expected = IllegalArgumentException.class)
  public void getRawContentNullPath2() throws IOException {
    BlobUtils.getRawContent(new FileRepository(testRepo), "master", null);
  }
View Full Code Here

   *
   * @throws IOException
   */
  @Test(expected = IllegalArgumentException.class)
  public void getRawContentEmptyPath() throws IOException {
    BlobUtils.getRawContent(new FileRepository(testRepo),
        ObjectId.zeroId(), "");
  }
View Full Code Here

   *
   * @throws IOException
   */
  @Test(expected = IllegalArgumentException.class)
  public void getRawContentEmptyPath2() throws IOException {
    BlobUtils.getRawContent(new FileRepository(testRepo), "master", "");
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void getContent() throws Exception {
    RevCommit commit = add("test.txt", "content");
    assertEquals("content", BlobUtils.getContent(new FileRepository(
        testRepo), commit, "test.txt"));
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void getStream() throws Exception {
    RevCommit commit = add("test.txt", "content");
    assertNotNull("content", BlobUtils.getStream(new FileRepository(
        testRepo), commit, "test.txt"));
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void getStreamNonExistentPath() throws Exception {
    RevCommit commit = add("test.txt", "content");
    assertNull("content", BlobUtils.getStream(new FileRepository(testRepo),
        commit, "test2.txt"));
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void getHeadStreamNonExistentPath() throws Exception {
    add("test.txt", "content");
    assertNull("content", BlobUtils.getHeadStream(new FileRepository(
        testRepo), "test2.txt"));
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void getHeadStream() throws Exception {
    add("test.txt", "content");
    assertNotNull("content", BlobUtils.getHeadStream(new FileRepository(
        testRepo), "test.txt"));
  }
View Full Code Here

TOP

Related Classes of org.eclipse.jgit.storage.file.FileRepository

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.