implement recursive option for git browse command

This commit is contained in:
Sebastian Sdorra
2013-01-19 13:09:58 +01:00
parent ab85fb9bf6
commit cc4604b60f
2 changed files with 46 additions and 10 deletions

View File

@@ -30,6 +30,7 @@
*/
package sonia.scm.repository.spi;
//~--- non-JDK imports --------------------------------------------------------
@@ -159,6 +160,31 @@ public class GitBrowseCommandTest extends AbstractGitCommandTestBase
checkDate(e.getLastModified());
}
/**
* Method description
*
*
* @throws IOException
* @throws RepositoryException
*/
@Test
public void testRecusive() throws IOException, RepositoryException
{
BrowseCommandRequest request = new BrowseCommandRequest();
request.setRecursive(true);
BrowserResult result = createCommand().getBrowserResult(request);
assertNotNull(result);
List<FileObject> foList = result.getFiles();
assertNotNull(foList);
assertFalse(foList.isEmpty());
assertEquals(5, foList.size());
}
/**
* Method description
*