Exemplo n.º 1
0
 /**
  * Test method for {@link
  * hudson.plugins.git.browser.GithubWeb#getFileLink(hudson.plugins.git.GitChangeSet.Path)}.
  *
  * @throws SAXException
  * @throws IOException
  */
 public void testGetFileLinkPathForDeletedFile() throws IOException, SAXException {
   final HashMap<String, Path> pathMap = createPathMap("rawchangelog-with-deleted-file");
   final Path path = pathMap.get("bar");
   final URL fileLink = rhodecode.getFileLink(path);
   assertEquals(
       RHODECODE_URL + "/files/b547aa10c3f06710c6fdfcdb2a9149c81662923b/bar",
       String.valueOf(fileLink));
 }
Exemplo n.º 2
0
 /**
  * Test method for {@link
  * hudson.plugins.git.browser.GithubWeb#getFileLink(hudson.plugins.git.GitChangeSet.Path)}.
  *
  * @throws SAXException
  * @throws IOException
  */
 public void testGetFileLinkPath() throws IOException, SAXException {
   final HashMap<String, Path> pathMap = createPathMap("rawchangelog");
   final Path path = pathMap.get("src/main/java/hudson/plugins/git/browser/GithubWeb.java");
   final URL fileLink = rhodecode.getFileLink(path);
   assertEquals(
       RHODECODE_URL
           + "/files/396fc230a3db05c427737aa5c2eb7856ba72b05d/src/main/java/hudson/plugins/git/browser/GithubWeb.java",
       String.valueOf(fileLink));
 }