diff options
Diffstat (limited to 'org.eclipse.jgit.junit/src/org')
-rw-r--r-- | org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/JGitTestUtil.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/JGitTestUtil.java b/org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/JGitTestUtil.java index d3da09ffbd..b3376a54be 100644 --- a/org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/JGitTestUtil.java +++ b/org.eclipse.jgit.junit/src/org/eclipse/jgit/junit/JGitTestUtil.java @@ -141,6 +141,14 @@ public abstract class JGitTestUtil { return path; } + public static File writeTrashFile(final FileRepository db, + final String subdir, + final String name, final String data) throws IOException { + File path = new File(db.getWorkTree() + "/" + subdir, name); + write(path, data); + return path; + } + /** * Write a string as a UTF-8 file. * |