diff options
author | Shawn Pearce <spearce@spearce.org> | 2013-03-18 07:44:48 -0700 |
---|---|---|
committer | Shawn Pearce <spearce@spearce.org> | 2013-03-18 09:30:43 -0700 |
commit | f32b8612433e499090c76ded014dd5e94322b786 (patch) | |
tree | 775440020e0b1d60d8cd86b027c9bebf487caa54 /org.eclipse.jgit.test | |
parent | 462bbc052e766ee9ea585cd4366165a8dac86496 (diff) | |
download | jgit-f32b8612433e499090c76ded014dd5e94322b786.tar.gz jgit-f32b8612433e499090c76ded014dd5e94322b786.zip |
JGit 3.0: move internal classes into an internal subpackage
This breaks all existing callers once. Applications are not supposed
to build against the internal storage API unless they can accept API
churn and make necessary updates as versions change.
Change-Id: I2ab1327c202ef2003565e1b0770a583970e432e9
Diffstat (limited to 'org.eclipse.jgit.test')
44 files changed, 163 insertions, 112 deletions
diff --git a/org.eclipse.jgit.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.test/META-INF/MANIFEST.MF index dbdf0c9cdf..f51d1d4d41 100644 --- a/org.eclipse.jgit.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.test/META-INF/MANIFEST.MF @@ -2,42 +2,44 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %plugin_name Bundle-SymbolicName: org.eclipse.jgit.test -Bundle-Version: 2.4.0.qualifier +Bundle-Version: 3.0.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %provider_name Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: J2SE-1.5 Import-Package: javaewah;version="0.5.6", - org.eclipse.jgit.api;version="[2.4.0,2.5.0)", - org.eclipse.jgit.api.errors;version="[2.4.0,2.5.0)", - org.eclipse.jgit.awtui;version="[2.4.0,2.5.0)", - org.eclipse.jgit.blame;version="[2.4.0,2.5.0)", - org.eclipse.jgit.console;version="[2.4.0,2.5.0)", - org.eclipse.jgit.diff;version="[2.4.0,2.5.0)", - org.eclipse.jgit.dircache;version="[2.4.0,2.5.0)", - org.eclipse.jgit.errors;version="[2.4.0,2.5.0)", - org.eclipse.jgit.events;version="[2.4.0,2.5.0)", - org.eclipse.jgit.fnmatch;version="[2.4.0,2.5.0)", - org.eclipse.jgit.ignore;version="[2.4.0,2.5.0)", - org.eclipse.jgit.internal;version="[2.4.0,2.5.0)", - org.eclipse.jgit.junit;version="[2.4.0,2.5.0)", - org.eclipse.jgit.lib;version="[2.4.0,2.5.0)", - org.eclipse.jgit.merge;version="[2.4.0,2.5.0)", - org.eclipse.jgit.nls;version="[2.4.0,2.5.0)", - org.eclipse.jgit.notes;version="[2.4.0,2.5.0)", - org.eclipse.jgit.patch;version="[2.4.0,2.5.0)", - org.eclipse.jgit.pgm;version="[2.4.0,2.5.0)", - org.eclipse.jgit.revplot;version="[2.4.0,2.5.0)", - org.eclipse.jgit.revwalk;version="[2.4.0,2.5.0)", - org.eclipse.jgit.revwalk.filter;version="[2.4.0,2.5.0)", - org.eclipse.jgit.storage.file;version="[2.4.0,2.5.0)", - org.eclipse.jgit.storage.pack;version="[2.4.0,2.5.0)", - org.eclipse.jgit.submodule;version="[2.4.0,2.5.0)", - org.eclipse.jgit.transport;version="[2.4.0,2.5.0)", - org.eclipse.jgit.treewalk;version="[2.4.0,2.5.0)", - org.eclipse.jgit.treewalk.filter;version="[2.4.0,2.5.0)", - org.eclipse.jgit.util;version="[2.4.0,2.5.0)", - org.eclipse.jgit.util.io;version="[2.4.0,2.5.0)", + org.eclipse.jgit.api;version="[3.0.0,3.1.0)", + org.eclipse.jgit.api.errors;version="[3.0.0,3.1.0)", + org.eclipse.jgit.awtui;version="[3.0.0,3.1.0)", + org.eclipse.jgit.blame;version="[3.0.0,3.1.0)", + org.eclipse.jgit.console;version="[3.0.0,3.1.0)", + org.eclipse.jgit.diff;version="[3.0.0,3.1.0)", + org.eclipse.jgit.dircache;version="[3.0.0,3.1.0)", + org.eclipse.jgit.errors;version="[3.0.0,3.1.0)", + org.eclipse.jgit.events;version="[3.0.0,3.1.0)", + org.eclipse.jgit.fnmatch;version="[3.0.0,3.1.0)", + org.eclipse.jgit.ignore;version="[3.0.0,3.1.0)", + org.eclipse.jgit.internal;version="[3.0.0,3.1.0)", + org.eclipse.jgit.internal.storage.file;version="[3.0.0,3.1.0)", + org.eclipse.jgit.internal.storage.pack;version="[3.0.0,3.1.0)", + org.eclipse.jgit.junit;version="[3.0.0,3.1.0)", + org.eclipse.jgit.lib;version="[3.0.0,3.1.0)", + org.eclipse.jgit.merge;version="[3.0.0,3.1.0)", + org.eclipse.jgit.nls;version="[3.0.0,3.1.0)", + org.eclipse.jgit.notes;version="[3.0.0,3.1.0)", + org.eclipse.jgit.patch;version="[3.0.0,3.1.0)", + org.eclipse.jgit.pgm;version="[3.0.0,3.1.0)", + org.eclipse.jgit.revplot;version="[3.0.0,3.1.0)", + org.eclipse.jgit.revwalk;version="[3.0.0,3.1.0)", + org.eclipse.jgit.revwalk.filter;version="[3.0.0,3.1.0)", + org.eclipse.jgit.storage.file;version="[3.0.0,3.1.0)", + org.eclipse.jgit.storage.pack;version="[3.0.0,3.1.0)", + org.eclipse.jgit.submodule;version="[3.0.0,3.1.0)", + org.eclipse.jgit.transport;version="[3.0.0,3.1.0)", + org.eclipse.jgit.treewalk;version="[3.0.0,3.1.0)", + org.eclipse.jgit.treewalk.filter;version="[3.0.0,3.1.0)", + org.eclipse.jgit.util;version="[3.0.0,3.1.0)", + org.eclipse.jgit.util.io;version="[3.0.0,3.1.0)", org.hamcrest;version="[1.1.0,2.0.0)", org.hamcrest.text.pattern;version="[1.1.0,2.0.0)", org.junit;version="[4.4.0,5.0.0)", @@ -45,4 +47,4 @@ Import-Package: javaewah;version="0.5.6", org.junit.runner;version="[4.4.0,5.0.0)" Require-Bundle: com.jcraft.jsch;bundle-version="[0.1.37,0.2.0)", org.hamcrest.core;bundle-version="[1.1.0,2.0.0)" -Export-Package: org.eclipse.jgit.lib;version="2.4.0" +Export-Package: org.eclipse.jgit.lib;version="3.0.0" diff --git a/org.eclipse.jgit.test/pom.xml b/org.eclipse.jgit.test/pom.xml index 5f5659f45b..64d34caecd 100644 --- a/org.eclipse.jgit.test/pom.xml +++ b/org.eclipse.jgit.test/pom.xml @@ -52,7 +52,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>2.4.0-SNAPSHOT</version> + <version>3.0.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.test</artifactId> diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CherryPickCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CherryPickCommandTest.java index 0130bdf4d9..faaac55ea8 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CherryPickCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CherryPickCommandTest.java @@ -56,6 +56,7 @@ import org.eclipse.jgit.api.ResetCommand.ResetType; import org.eclipse.jgit.api.errors.GitAPIException; import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.dircache.DirCache; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; @@ -63,7 +64,6 @@ import org.eclipse.jgit.lib.FileMode; import org.eclipse.jgit.lib.RepositoryState; import org.eclipse.jgit.merge.ResolveMerger.MergeFailureReason; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.ReflogReader; import org.junit.Test; /** diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTests.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTests.java index 07e3c480f8..e5680273c0 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTests.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTests.java @@ -56,13 +56,13 @@ import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.api.errors.NoMessageException; import org.eclipse.jgit.errors.IncorrectObjectTypeException; import org.eclipse.jgit.errors.MissingObjectException; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.PersonIdent; import org.eclipse.jgit.lib.RefUpdate; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.ReflogReader; import org.eclipse.jgit.treewalk.TreeWalk; import org.eclipse.jgit.util.FS; import org.eclipse.jgit.util.FileUtils; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandTest.java index 771769717f..ac7584949b 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandTest.java @@ -56,6 +56,7 @@ import java.io.IOException; import org.eclipse.jgit.api.CreateBranchCommand.SetupUpstreamMode; import org.eclipse.jgit.api.MergeResult.MergeStatus; import org.eclipse.jgit.api.errors.NoHeadException; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; @@ -65,7 +66,6 @@ import org.eclipse.jgit.lib.RepositoryState; import org.eclipse.jgit.lib.StoredConfig; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.transport.RefSpec; import org.eclipse.jgit.transport.RemoteConfig; import org.eclipse.jgit.transport.URIish; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandWithRebaseTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandWithRebaseTest.java index e87eb1113b..51ebf72bfd 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandWithRebaseTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PullCommandWithRebaseTest.java @@ -57,6 +57,7 @@ import java.io.IOException; import org.eclipse.jgit.api.CreateBranchCommand.SetupUpstreamMode; import org.eclipse.jgit.api.MergeResult.MergeStatus; import org.eclipse.jgit.api.RebaseResult.Status; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; @@ -67,7 +68,6 @@ import org.eclipse.jgit.lib.StoredConfig; import org.eclipse.jgit.merge.MergeStrategy; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.transport.RefSpec; import org.eclipse.jgit.transport.RemoteConfig; import org.eclipse.jgit.transport.URIish; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ReflogCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ReflogCommandTest.java index a43e0369c4..a30b4963f9 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ReflogCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/ReflogCommandTest.java @@ -47,11 +47,11 @@ import static org.junit.Assert.assertNotNull; import java.util.Collection; +import org.eclipse.jgit.internal.storage.file.ReflogEntry; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.ReflogEntry; import org.junit.Before; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RevertCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RevertCommandTest.java index 228e11dfb7..01aaa7bd71 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RevertCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RevertCommandTest.java @@ -57,6 +57,7 @@ import org.eclipse.jgit.api.ResetCommand.ResetType; import org.eclipse.jgit.api.errors.GitAPIException; import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.dircache.DirCache; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; @@ -64,7 +65,6 @@ import org.eclipse.jgit.lib.FileMode; import org.eclipse.jgit.lib.RepositoryState; import org.eclipse.jgit.merge.ResolveMerger.MergeFailureReason; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.ReflogReader; import org.junit.Test; /** diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashCreateCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashCreateCommandTest.java index f91229d84e..f7eba5814f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashCreateCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashCreateCommandTest.java @@ -54,6 +54,8 @@ import java.util.List; import org.eclipse.jgit.api.errors.UnmergedPathsException; import org.eclipse.jgit.diff.DiffEntry; +import org.eclipse.jgit.internal.storage.file.ReflogEntry; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; @@ -61,8 +63,6 @@ import org.eclipse.jgit.lib.PersonIdent; import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.file.ReflogEntry; -import org.eclipse.jgit.storage.file.ReflogReader; import org.eclipse.jgit.treewalk.TreeWalk; import org.eclipse.jgit.treewalk.filter.TreeFilter; import org.eclipse.jgit.util.FileUtils; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java index 571ff6d7b0..43f063f04d 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java @@ -52,13 +52,13 @@ import java.io.File; import java.util.List; import org.eclipse.jgit.api.errors.JGitInternalException; +import org.eclipse.jgit.internal.storage.file.ReflogEntry; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.ReflogEntry; -import org.eclipse.jgit.storage.file.ReflogReader; import org.junit.Before; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/AbbreviationTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/AbbreviationTest.java index c099bb0bd3..dd43dbba82 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/AbbreviationTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/AbbreviationTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.eclipse.jgit.lib.Constants.OBJECT_ID_LENGTH; import static org.eclipse.jgit.lib.Constants.OBJECT_ID_STRING_LENGTH; @@ -60,6 +60,9 @@ import java.util.Collection; import java.util.List; import org.eclipse.jgit.errors.AmbiguousObjectException; +import org.eclipse.jgit.internal.storage.file.FileRepository; +import org.eclipse.jgit.internal.storage.file.PackIndexWriter; +import org.eclipse.jgit.internal.storage.file.PackIndexWriterV2; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.AbbreviatedObjectId; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ConcurrentRepackTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ConcurrentRepackTest.java index 2e3b1d1a22..562cde72ca 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ConcurrentRepackTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ConcurrentRepackTest.java @@ -42,7 +42,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -55,8 +55,10 @@ import java.io.File; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStream; + import org.eclipse.jgit.errors.IncorrectObjectTypeException; import org.eclipse.jgit.errors.MissingObjectException; +import org.eclipse.jgit.internal.storage.pack.PackWriter; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.Constants; @@ -67,7 +69,7 @@ import org.eclipse.jgit.lib.ObjectLoader; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevObject; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.pack.PackWriter; +import org.eclipse.jgit.storage.file.WindowCacheConfig; import org.eclipse.jgit.util.FileUtils; import org.eclipse.jgit.util.io.SafeBufferedOutputStream; import org.junit.After; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/FileRepositoryBuilderTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/FileRepositoryBuilderTest.java index 8f3f488296..2c811671d8 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/FileRepositoryBuilderTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/FileRepositoryBuilderTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; @@ -55,6 +55,8 @@ import java.io.IOException; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; +import org.eclipse.jgit.storage.file.FileBasedConfig; +import org.eclipse.jgit.storage.file.FileRepositoryBuilder; import org.eclipse.jgit.util.FileUtils; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/FileSnapshotTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/FileSnapshotTest.java index 22fc4c70c8..17c44dce82 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/FileSnapshotTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/FileSnapshotTest.java @@ -40,7 +40,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; @@ -51,6 +51,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.eclipse.jgit.internal.storage.file.FileSnapshot; import org.eclipse.jgit.util.FileUtils; import org.junit.After; import org.junit.Before; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/GCTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GCTest.java index c61ea732f8..8f26f7058d 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/GCTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GCTest.java @@ -40,7 +40,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static java.lang.Integer.valueOf; import static org.junit.Assert.assertEquals; @@ -63,6 +63,15 @@ import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; import org.eclipse.jgit.internal.JGitText; +import org.eclipse.jgit.internal.storage.file.FileRepository; +import org.eclipse.jgit.internal.storage.file.GC; +import org.eclipse.jgit.internal.storage.file.LockFile; +import org.eclipse.jgit.internal.storage.file.PackFile; +import org.eclipse.jgit.internal.storage.file.PackIndex; +import org.eclipse.jgit.internal.storage.file.RefDirectory; +import org.eclipse.jgit.internal.storage.file.RefDirectoryUpdate; +import org.eclipse.jgit.internal.storage.file.GC.RepoStatistics; +import org.eclipse.jgit.internal.storage.file.PackIndex.MutableEntry; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; @@ -81,8 +90,6 @@ import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevTag; import org.eclipse.jgit.revwalk.RevTree; -import org.eclipse.jgit.storage.file.GC.RepoStatistics; -import org.eclipse.jgit.storage.file.PackIndex.MutableEntry; import org.eclipse.jgit.util.FileUtils; import org.junit.After; import org.junit.Before; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/InflatingBitSetTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/InflatingBitSetTest.java index 811096e3db..f4f66c8f29 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/InflatingBitSetTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/InflatingBitSetTest.java @@ -41,13 +41,14 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import javaewah.EWAHCompressedBitmap; +import org.eclipse.jgit.internal.storage.file.InflatingBitSet; import org.junit.Test; public class InflatingBitSetTest { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/LockFileTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java index a5cf5cc2d7..1a3a567f9f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/LockFileTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java @@ -40,7 +40,7 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; @@ -49,6 +49,7 @@ import static org.junit.Assert.fail; import org.eclipse.jgit.api.Git; import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.errors.LockFailedException; +import org.eclipse.jgit.internal.storage.file.LockFile; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.revwalk.RevCommit; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ObjectDirectoryTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ObjectDirectoryTest.java index de6cd4c756..3226f42e07 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ObjectDirectoryTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ObjectDirectoryTest.java @@ -40,7 +40,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import java.util.Collection; import java.util.Collections; @@ -49,6 +49,7 @@ import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Future; +import org.eclipse.jgit.internal.storage.file.ObjectDirectory; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackFileTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackFileTest.java index 11082bd1f3..64941995de 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackFileTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackFileTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -60,6 +60,7 @@ import java.util.zip.Deflater; import org.eclipse.jgit.errors.LargeObjectException; import org.eclipse.jgit.internal.JGitText; +import org.eclipse.jgit.internal.storage.pack.DeltaEncoder; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; @@ -71,7 +72,7 @@ import org.eclipse.jgit.lib.ObjectInserter; import org.eclipse.jgit.lib.ObjectLoader; import org.eclipse.jgit.lib.ObjectStream; import org.eclipse.jgit.revwalk.RevBlob; -import org.eclipse.jgit.storage.pack.DeltaEncoder; +import org.eclipse.jgit.storage.file.WindowCacheConfig; import org.eclipse.jgit.transport.PackParser; import org.eclipse.jgit.util.IO; import org.eclipse.jgit.util.NB; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexTestCase.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexTestCase.java index 9294172f13..aa3817e3ad 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexTestCase.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexTestCase.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -52,8 +52,9 @@ import java.util.Iterator; import java.util.NoSuchElementException; import org.eclipse.jgit.errors.MissingObjectException; +import org.eclipse.jgit.internal.storage.file.PackIndex; +import org.eclipse.jgit.internal.storage.file.PackIndex.MutableEntry; import org.eclipse.jgit.junit.RepositoryTestCase; -import org.eclipse.jgit.storage.file.PackIndex.MutableEntry; import org.junit.Test; public abstract class PackIndexTestCase extends RepositoryTestCase { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexV1Test.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexV1Test.java index 8231958352..3de46ca659 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexV1Test.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexV1Test.java @@ -43,7 +43,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertFalse; import static org.junit.Assert.fail; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexV2Test.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexV2Test.java index 039cd6f3d5..0e2e2eb3e8 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackIndexV2Test.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackIndexV2Test.java @@ -43,7 +43,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertTrue; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackReverseIndexTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackReverseIndexTest.java index 530636f823..2126cac97a 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackReverseIndexTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackReverseIndexTest.java @@ -42,7 +42,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNull; @@ -50,9 +50,11 @@ import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; import org.eclipse.jgit.errors.CorruptObjectException; +import org.eclipse.jgit.internal.storage.file.PackIndex; +import org.eclipse.jgit.internal.storage.file.PackReverseIndex; +import org.eclipse.jgit.internal.storage.file.PackIndex.MutableEntry; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.RepositoryTestCase; -import org.eclipse.jgit.storage.file.PackIndex.MutableEntry; import org.junit.Before; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackWriterTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackWriterTest.java index 4ef9698c55..75ccb6b576 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/PackWriterTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/PackWriterTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -63,6 +63,9 @@ import java.util.List; import java.util.Set; import org.eclipse.jgit.errors.MissingObjectException; +import org.eclipse.jgit.internal.storage.file.PackIndex.MutableEntry; +import org.eclipse.jgit.internal.storage.pack.PackWriter; +import org.eclipse.jgit.internal.storage.pack.PackWriter.ObjectIdSet; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; @@ -75,10 +78,7 @@ import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevObject; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.file.PackIndex.MutableEntry; import org.eclipse.jgit.storage.pack.PackConfig; -import org.eclipse.jgit.storage.pack.PackWriter; -import org.eclipse.jgit.storage.pack.PackWriter.ObjectIdSet; import org.eclipse.jgit.transport.PackParser; import org.junit.After; import org.junit.Before; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RefDirectoryTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java index a602f7c7d5..7d39d0900a 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RefDirectoryTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.eclipse.jgit.lib.Constants.HEAD; import static org.eclipse.jgit.lib.Constants.R_HEADS; @@ -67,6 +67,8 @@ import java.util.concurrent.atomic.AtomicReference; import org.eclipse.jgit.events.ListenerHandle; import org.eclipse.jgit.events.RefsChangedEvent; import org.eclipse.jgit.events.RefsChangedListener; +import org.eclipse.jgit.internal.storage.file.FileRepository; +import org.eclipse.jgit.internal.storage.file.RefDirectory; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.AnyObjectId; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RefUpdateTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java index cd56d28153..08e49d3dd5 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RefUpdateTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java @@ -43,7 +43,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.eclipse.jgit.junit.Assert.assertEquals; import static org.junit.Assert.assertEquals; @@ -61,6 +61,11 @@ import java.util.List; import java.util.Map; import java.util.Map.Entry; +import org.eclipse.jgit.internal.storage.file.FileRepository; +import org.eclipse.jgit.internal.storage.file.LockFile; +import org.eclipse.jgit.internal.storage.file.RefDirectory; +import org.eclipse.jgit.internal.storage.file.RefDirectoryUpdate; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.Constants; @@ -122,14 +127,14 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { assertNotSame(newid, r.getObjectId()); assertSame(ObjectId.class, r.getObjectId().getClass()); assertEquals(newid, r.getObjectId()); - List<org.eclipse.jgit.storage.file.ReflogEntry> reverseEntries1 = db.getReflogReader("refs/heads/abc").getReverseEntries(); - org.eclipse.jgit.storage.file.ReflogEntry entry1 = reverseEntries1.get(0); + List<org.eclipse.jgit.internal.storage.file.ReflogEntry> reverseEntries1 = db.getReflogReader("refs/heads/abc").getReverseEntries(); + org.eclipse.jgit.internal.storage.file.ReflogEntry entry1 = reverseEntries1.get(0); assertEquals(1, reverseEntries1.size()); assertEquals(ObjectId.zeroId(), entry1.getOldId()); assertEquals(r.getObjectId(), entry1.getNewId()); assertEquals(new PersonIdent(db).toString(), entry1.getWho().toString()); assertEquals("", entry1.getComment()); - List<org.eclipse.jgit.storage.file.ReflogEntry> reverseEntries2 = db.getReflogReader("HEAD").getReverseEntries(); + List<org.eclipse.jgit.internal.storage.file.ReflogEntry> reverseEntries2 = db.getReflogReader("HEAD").getReverseEntries(); assertEquals(0, reverseEntries2.size()); } @@ -335,7 +340,7 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { // the branch HEAD referred to is left untouched assertEquals(pid, db.resolve("refs/heads/master")); ReflogReader reflogReader = new ReflogReader(db, "HEAD"); - org.eclipse.jgit.storage.file.ReflogEntry e = reflogReader.getReverseEntries().get(0); + org.eclipse.jgit.internal.storage.file.ReflogEntry e = reflogReader.getReverseEntries().get(0); assertEquals(pid, e.getOldId()); assertEquals(ppid, e.getNewId()); assertEquals("GIT_COMMITTER_EMAIL", e.getWho().getEmailAddress()); @@ -365,7 +370,7 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { // the branch HEAD referred to is left untouched assertNull(db.resolve("refs/heads/unborn")); ReflogReader reflogReader = new ReflogReader(db, "HEAD"); - org.eclipse.jgit.storage.file.ReflogEntry e = reflogReader.getReverseEntries().get(0); + org.eclipse.jgit.internal.storage.file.ReflogEntry e = reflogReader.getReverseEntries().get(0); assertEquals(ObjectId.zeroId(), e.getOldId()); assertEquals(ppid, e.getNewId()); assertEquals("GIT_COMMITTER_EMAIL", e.getWho().getEmailAddress()); @@ -701,9 +706,9 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { ObjectId oldfromId = db.resolve(fromName); ObjectId oldHeadId = db.resolve(Constants.HEAD); writeReflog(db, oldfromId, "Just a message", fromName); - List<org.eclipse.jgit.storage.file.ReflogEntry> oldFromLog = db + List<org.eclipse.jgit.internal.storage.file.ReflogEntry> oldFromLog = db .getReflogReader(fromName).getReverseEntries(); - List<org.eclipse.jgit.storage.file.ReflogEntry> oldHeadLog = oldHeadId != null ? db + List<org.eclipse.jgit.internal.storage.file.ReflogEntry> oldHeadLog = oldHeadId != null ? db .getReflogReader(Constants.HEAD).getReverseEntries() : null; assertTrue("internal check, we have a log", new File(db.getDirectory(), diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ReflogReaderTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ReflogReaderTest.java index e52c89f602..65367a8c18 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/ReflogReaderTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/ReflogReaderTest.java @@ -42,7 +42,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; @@ -55,6 +55,9 @@ import java.io.IOException; import java.text.SimpleDateFormat; import java.util.List; +import org.eclipse.jgit.internal.storage.file.CheckoutEntry; +import org.eclipse.jgit.internal.storage.file.ReflogEntry; +import org.eclipse.jgit.internal.storage.file.ReflogReader; import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RepositorySetupWorkDirTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RepositorySetupWorkDirTest.java index 8aaeb49709..20896001ca 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/RepositorySetupWorkDirTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RepositorySetupWorkDirTest.java @@ -42,7 +42,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -58,6 +58,8 @@ import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.Repository; +import org.eclipse.jgit.storage.file.FileBasedConfig; +import org.eclipse.jgit.storage.file.FileRepositoryBuilder; import org.eclipse.jgit.util.FS; import org.eclipse.jgit.util.FileUtils; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/StoredBitmapTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/StoredBitmapTest.java index 9170e6e3c4..dc4c25e051 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/StoredBitmapTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/StoredBitmapTest.java @@ -41,14 +41,14 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.*; import javaewah.EWAHCompressedBitmap; +import org.eclipse.jgit.internal.storage.file.BasePackBitmapIndex.StoredBitmap; import org.eclipse.jgit.lib.ObjectId; -import org.eclipse.jgit.storage.file.BasePackBitmapIndex.StoredBitmap; import org.junit.Test; public class StoredBitmapTest { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/T0003_BasicTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/T0003_BasicTest.java index f97bdd1de0..a4de35ee97 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/T0003_BasicTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/T0003_BasicTest.java @@ -44,7 +44,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -81,6 +81,8 @@ import org.eclipse.jgit.lib.TreeFormatter; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevTag; import org.eclipse.jgit.revwalk.RevWalk; +import org.eclipse.jgit.storage.file.FileBasedConfig; +import org.eclipse.jgit.storage.file.FileRepositoryBuilder; import org.eclipse.jgit.util.FileUtils; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/T0004_PackReaderTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/T0004_PackReaderTest.java index d14cc212af..dc78909d4a 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/T0004_PackReaderTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/T0004_PackReaderTest.java @@ -44,16 +44,18 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; -import static org.eclipse.jgit.storage.pack.PackExt.INDEX; -import static org.eclipse.jgit.storage.pack.PackExt.PACK; +import static org.eclipse.jgit.internal.storage.pack.PackExt.INDEX; +import static org.eclipse.jgit.internal.storage.pack.PackExt.PACK; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import java.io.File; import java.io.IOException; +import org.eclipse.jgit.internal.storage.file.PackFile; +import org.eclipse.jgit.internal.storage.file.WindowCursor; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.lib.Constants; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/UnpackedObjectTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/UnpackedObjectTest.java index 16580b49a0..10d2b6b526 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/UnpackedObjectTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/UnpackedObjectTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -71,6 +71,7 @@ import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectInserter; import org.eclipse.jgit.lib.ObjectLoader; import org.eclipse.jgit.lib.ObjectStream; +import org.eclipse.jgit.storage.file.WindowCacheConfig; import org.eclipse.jgit.util.FileUtils; import org.eclipse.jgit.util.IO; import org.junit.After; @@ -98,7 +99,7 @@ public class UnpackedObjectTest extends LocalDiskRepositoryTestCase { WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setStreamFileThreshold(streamThreshold); - WindowCache.reconfigure(cfg); + cfg.install(); repo = createBareRepository(); wc = (WindowCursor) repo.newObjectReader(); @@ -108,7 +109,7 @@ public class UnpackedObjectTest extends LocalDiskRepositoryTestCase { public void tearDown() throws Exception { if (wc != null) wc.release(); - WindowCache.reconfigure(new WindowCacheConfig()); + new WindowCacheConfig().install(); super.tearDown(); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/WindowCacheGetTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/WindowCacheGetTest.java index 98ae3dac6a..f0942203b5 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/WindowCacheGetTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/WindowCacheGetTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; @@ -60,6 +60,7 @@ import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectLoader; +import org.eclipse.jgit.storage.file.WindowCacheConfig; import org.eclipse.jgit.util.MutableInteger; import org.junit.Before; import org.junit.Test; @@ -97,8 +98,8 @@ public class WindowCacheGetTest extends SampleDataRepositoryTestCase { @Test public void testCache_Defaults() throws IOException { - final WindowCacheConfig cfg = new WindowCacheConfig(); - WindowCache.reconfigure(cfg); + WindowCacheConfig cfg = new WindowCacheConfig(); + cfg.install(); doCacheTests(); checkLimits(cfg); @@ -111,7 +112,7 @@ public class WindowCacheGetTest extends SampleDataRepositoryTestCase { public void testCache_TooFewFiles() throws IOException { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitOpenFiles(2); - WindowCache.reconfigure(cfg); + cfg.install(); doCacheTests(); checkLimits(cfg); } @@ -121,7 +122,7 @@ public class WindowCacheGetTest extends SampleDataRepositoryTestCase { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitWindowSize(4096); cfg.setPackedGitLimit(4096); - WindowCache.reconfigure(cfg); + cfg.install(); doCacheTests(); checkLimits(cfg); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/WindowCacheReconfigureTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/WindowCacheReconfigureTest.java index 467c1ac7b7..2b7ee64724 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/WindowCacheReconfigureTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/WindowCacheReconfigureTest.java @@ -41,12 +41,13 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import static org.junit.Assert.assertEquals; import static org.junit.Assert.fail; import org.eclipse.jgit.junit.RepositoryTestCase; +import org.eclipse.jgit.storage.file.WindowCacheConfig; import org.junit.Test; public class WindowCacheReconfigureTest extends RepositoryTestCase { @@ -55,7 +56,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { try { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitLimit(0); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitLimit = 0"); } catch (IllegalArgumentException e) { // @@ -67,7 +68,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { try { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitWindowSize(0); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitWindowSize = 0"); } catch (IllegalArgumentException e) { assertEquals("Invalid window size", e.getMessage()); @@ -79,7 +80,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { try { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitWindowSize(512); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitWindowSize = 512"); } catch (IllegalArgumentException e) { assertEquals("Invalid window size", e.getMessage()); @@ -91,7 +92,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { try { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitWindowSize(4097); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitWindowSize = 4097"); } catch (IllegalArgumentException e) { assertEquals("Window size must be power of 2", e.getMessage()); @@ -103,7 +104,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { try { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitOpenFiles(0); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitOpenFiles = 0"); } catch (IllegalArgumentException e) { assertEquals("Open files must be >= 1", e.getMessage()); @@ -116,7 +117,7 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitLimit(1024); cfg.setPackedGitWindowSize(8192); - WindowCache.reconfigure(cfg); + cfg.install(); fail("incorrectly permitted PackedGitWindowSize > PackedGitLimit"); } catch (IllegalArgumentException e) { assertEquals("Window size must be < limit", e.getMessage()); @@ -133,6 +134,6 @@ public class WindowCacheReconfigureTest extends RepositoryTestCase { final WindowCacheConfig cfg = new WindowCacheConfig(); cfg.setPackedGitLimit(6 * 4096 / 5); cfg.setPackedGitWindowSize(4096); - WindowCache.reconfigure(cfg); + cfg.install(); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/XInputStream.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/XInputStream.java index 9978c8e13c..46f9ee3fff 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/file/XInputStream.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/XInputStream.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.file; +package org.eclipse.jgit.internal.storage.file; import java.io.BufferedInputStream; import java.io.EOFException; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/DeltaIndexTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/DeltaIndexTest.java index 59acaf62b0..bb94a370ad 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/DeltaIndexTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/DeltaIndexTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.pack; +package org.eclipse.jgit.internal.storage.pack; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -50,6 +50,10 @@ import static org.junit.Assert.assertTrue; import java.io.ByteArrayOutputStream; import java.io.IOException; + +import org.eclipse.jgit.internal.storage.pack.BinaryDelta; +import org.eclipse.jgit.internal.storage.pack.DeltaEncoder; +import org.eclipse.jgit.internal.storage.pack.DeltaIndex; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.TestRng; import org.eclipse.jgit.lib.Constants; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/DeltaStreamTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/DeltaStreamTest.java index 9b39d79735..3ea09179de 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/DeltaStreamTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/DeltaStreamTest.java @@ -41,7 +41,7 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.pack; +package org.eclipse.jgit.internal.storage.pack; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -57,6 +57,9 @@ import java.util.Arrays; import org.eclipse.jgit.errors.CorruptObjectException; import org.eclipse.jgit.internal.JGitText; +import org.eclipse.jgit.internal.storage.pack.BinaryDelta; +import org.eclipse.jgit.internal.storage.pack.DeltaEncoder; +import org.eclipse.jgit.internal.storage.pack.DeltaStream; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.TestRng; import org.eclipse.jgit.lib.Constants; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/IntSetTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/IntSetTest.java index f8838f8b59..7a45006858 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/storage/pack/IntSetTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/IntSetTest.java @@ -41,9 +41,10 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package org.eclipse.jgit.storage.pack; +package org.eclipse.jgit.internal.storage.pack; -import static org.junit.Assert.*; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertTrue; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/RecursiveMergerTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/RecursiveMergerTest.java index 9860d304f3..8f43f7f868 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/RecursiveMergerTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/RecursiveMergerTest.java @@ -58,6 +58,7 @@ import org.eclipse.jgit.dircache.DirCacheEntry; import org.eclipse.jgit.errors.MissingObjectException; import org.eclipse.jgit.errors.NoMergeBaseException; import org.eclipse.jgit.errors.NoMergeBaseException.MergeBaseFailureReason; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.junit.TestRepository.BranchBuilder; @@ -70,7 +71,6 @@ import org.eclipse.jgit.lib.ObjectReader; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.treewalk.FileTreeIterator; import org.eclipse.jgit.treewalk.TreeWalk; import org.eclipse.jgit.treewalk.filter.PathFilter; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java index 29c953f322..7712097203 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/submodule/SubmoduleWalkTest.java @@ -61,6 +61,7 @@ import org.eclipse.jgit.dircache.DirCacheEditor; import org.eclipse.jgit.dircache.DirCacheEditor.PathEdit; import org.eclipse.jgit.dircache.DirCacheEntry; import org.eclipse.jgit.errors.ConfigInvalidException; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.Config; @@ -70,7 +71,6 @@ import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; -import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.storage.file.FileRepositoryBuilder; import org.eclipse.jgit.treewalk.CanonicalTreeParser; import org.eclipse.jgit.treewalk.filter.PathFilter; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java index bb71e72244..6859dd53a6 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java @@ -62,6 +62,8 @@ import java.util.zip.Deflater; import org.eclipse.jgit.errors.TooLargeObjectInPackException; import org.eclipse.jgit.internal.JGitText; +import org.eclipse.jgit.internal.storage.file.ObjectDirectoryPackParser; +import org.eclipse.jgit.internal.storage.file.PackFile; import org.eclipse.jgit.junit.JGitTestUtil; import org.eclipse.jgit.junit.RepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; @@ -71,8 +73,6 @@ import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectInserter; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevBlob; -import org.eclipse.jgit.storage.file.ObjectDirectoryPackParser; -import org.eclipse.jgit.storage.file.PackFile; import org.eclipse.jgit.util.NB; import org.eclipse.jgit.util.TemporaryBuffer; import org.eclipse.jgit.util.io.UnionInputStream; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java index 8c3ce6196b..2bd9077677 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java @@ -62,6 +62,8 @@ import java.util.zip.Deflater; import org.eclipse.jgit.errors.MissingObjectException; import org.eclipse.jgit.errors.UnpackException; +import org.eclipse.jgit.internal.storage.file.ObjectDirectory; +import org.eclipse.jgit.internal.storage.pack.BinaryDelta; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.Constants; @@ -75,8 +77,6 @@ import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevTree; import org.eclipse.jgit.revwalk.RevWalk; -import org.eclipse.jgit.storage.file.ObjectDirectory; -import org.eclipse.jgit.storage.pack.BinaryDelta; import org.eclipse.jgit.util.NB; import org.eclipse.jgit.util.TemporaryBuffer; import org.junit.After; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/TransportTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/TransportTest.java index 60310b34ce..c6b3ba624e 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/TransportTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/TransportTest.java @@ -55,10 +55,10 @@ import java.util.Collection; import java.util.Collections; import java.util.List; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.SampleDataRepositoryTestCase; import org.eclipse.jgit.lib.Config; import org.eclipse.jgit.lib.ObjectId; -import org.eclipse.jgit.storage.file.FileRepository; import org.junit.After; import org.junit.Before; import org.junit.Test; diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/InterIndexDiffFilterTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/InterIndexDiffFilterTest.java index 13fe426873..f74c44cfe7 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/InterIndexDiffFilterTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/InterIndexDiffFilterTest.java @@ -53,11 +53,11 @@ import org.eclipse.jgit.dircache.DirCacheEditor; import org.eclipse.jgit.dircache.DirCacheEntry; import org.eclipse.jgit.dircache.DirCacheIterator; import org.eclipse.jgit.dircache.DirCacheEditor.PathEdit; +import org.eclipse.jgit.internal.storage.file.FileRepository; import org.eclipse.jgit.junit.LocalDiskRepositoryTestCase; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.FileMode; import org.eclipse.jgit.lib.ObjectId; -import org.eclipse.jgit.storage.file.FileRepository; import org.eclipse.jgit.treewalk.TreeWalk; import org.junit.Before; import org.junit.Test; |