Package org.eclipse.jgit.storage.file

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


   *
   * @throws Exception
   */
  @Test(expected = IllegalArgumentException.class)
  public void getStreamNullId() throws Exception {
    BlobUtils.getStream(new FileRepository(testRepo), (ObjectId) null,
        "test.txt");
  }
View Full Code Here


   *
   * @throws Exception
   */
  @Test(expected = IllegalArgumentException.class)
  public void getStreamNullRevision() throws Exception {
    BlobUtils.getStream(new FileRepository(testRepo), (String) null,
        "test.txt");
  }
View Full Code Here

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

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

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

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

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

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

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

   * @throws Exception
   */
  @Test
  public void getHeadContentNonExistentPath() throws Exception {
    add("test.txt", "content");
    assertNull(BlobUtils.getHeadContent(new FileRepository(testRepo),
        "test2.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.