aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.pgm.test
Commit message (Collapse)AuthorAgeFilesLines
* Prepare post 3.1.0 buildsstable-3.1Matthias Sohn2013-10-032-15/+15
| | | | | Change-Id: I306a3d40c6ddb88a16d17f09a60e3d19b0716962 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v3.1.0.201310021548-rv3.1.0.201310021548-rMatthias Sohn2013-10-022-2/+2
| | | | | Change-Id: I2170b13047d5eab7565f47f9feb1680e03b1ba09 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare post 3.1.0 RC1 buildsMatthias Sohn2013-09-272-2/+2
| | | | | Change-Id: I060f2082ccd0c91905b6b29a49cc633a0b51a1f2 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v3.1.0.201309270735-rc1v3.1.0.201309270735-rc1Matthias Sohn2013-09-272-2/+2
| | | | | Change-Id: I48202dd461110da25f9bc159c938311fff0669e0 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Add missing dependency for testing ArchiveCommand with xz compressionMatthias Sohn2013-09-081-0/+1
| | | | | | | Without this dependency the ArchiveTest.testTxzExtension() fails with a ClassNotFoundException if it is started from Eclipse. Change-Id: Ief2fceaaffab7641ba63ace4577462fa3bbf1c13 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Merge branch 'stable-3.0'Matthias Sohn2013-09-041-0/+19
|\ | | | | | | | | | | | | | | | | | | | | | | * stable-3.0: Prepare post 3.0.2-rc2 builds JGit v3.0.2.201309041250-rc2 Uncomment eclipse-jar-signer plugin Update build to use CBI jarsigner plugin Update maven plugins Update to Orbit Kepler SR1 release R20130827064939 Change-Id: Iaa8bba21c300dd1de2b91a77cddf6727fbc66340 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare post 3.0.2-rc2 buildsMatthias Sohn2013-09-042-2/+2
| | | | | | | | | | Change-Id: I0e4020326c6443ba7157c18b345160cf9e1e88a7 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * JGit v3.0.2.201309041250-rc2v3.0.2.201309041250-rc2Matthias Sohn2013-09-042-2/+2
| | | | | | | | Change-Id: Ie18ced75f573f140969af2a7d9edb45c76523715 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Update build to use CBI jarsigner pluginMatthias Sohn2013-09-041-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The dash signing plugin has been retired hence we need to update our build to use the CBI jarsigner plugin for signing build results. Pack test classes to enable signing them. Also re-enable pack200 for bundle org.eclipse.jgit. WORKAROUND: there is no easy way to run tests with maven-surefire-plugin from signed test-jar so for a quick workaround we will have to add a build step on Hudson so that we can run tests before signing: - first step will do "clean, verify" to compile and run tests - second step will do "install, deploy" with profile "eclipse-sign" and use -DskipTests=true to skip tests since they would hit a SecurityException when unsigned test classes are in same package as signed classes under test - third step will do "clean, install, deploy" on packaging reactor to build features and p2 repository with profile "eclipse-sign" to sign and pack200 all bundles. TODO: Tycho doesn't suport picking up pack200 artifacts via pomDependencies hence we need to find a way to copy them manually and use tycho-extra's tycho-p2-extras-plugin:publish-features-and-bundles to generate the missing p2 metadata. Change-Id: Iec2c5ab3027a3e3f9ecc0d2f99193385177d9025 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare 3.0.2-SNAPSHOT buildsMatthias Sohn2013-08-192-15/+15
| | | | | | | | | | Change-Id: I3287609a90f068017cc62f4fd7738651e0663081 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare post 3.0.0.201306101825-r buildsMatthias Sohn2013-06-132-2/+2
| | | | | | | | | | Change-Id: I299cf1addc0987ffe39140d2216ab6a98e95ce52 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * JGit v3.0.0.201306101825-rv3.0.0.201306101825-rMatthias Sohn2013-06-112-2/+2
| | | | | | | | | | Change-Id: Ie8deab94c6263b5198f0bcb4533b1cfb3f5724b1 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare post 3.0.0 RC3 buildsMatthias Sohn2013-06-042-2/+2
| | | | | | | | | | Change-Id: I008d55e2ef0aac9d1877b05ba73e3cf26335d430 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * JGit v3.0.0.201306040240-rc3v3.0.0.201306040240-rc3Matthias Sohn2013-06-042-2/+2
| | | | | | | | | | Change-Id: I8b782e9ebe03e5f72611a21a76d80c6b20cb7845 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare post 3.0.0-rc2 buildsMatthias Sohn2013-05-292-2/+2
| | | | | | | | Change-Id: Ic46832bcde80d0bf74c16cb094abd76b00552d14 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * JGit v3.0.0.201305281830-rc2v3.0.0.201305281830-rc2Matthias Sohn2013-05-292-2/+2
| | | | | | | | | | Change-Id: I490ad8cc7590f70783d3fbd6dd6f0e0446ae5afe Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * Prepare post 3.0.0 M7 buildsMatthias Sohn2013-05-082-2/+2
| | | | | | | | Change-Id: I062c44529c7ae2f960d3c64a0923a45d2dc8a863 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
| * JGit v3.0.0.201305080800-m7v3.0.0.201305080800-m7Matthias Sohn2013-05-082-2/+2
| | | | | | | | | | Change-Id: I377b174993862918a117f54e6cba4733dfc2307c Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | Add the other test launchers as favoritesRobin Rosenberg2013-06-162-0/+8
| | | | | | | | | | | | | | The user may not see them otherwise Change-Id: I43b7c0172870a9446cfb35c7b3fee6394f3292e3 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | Disable warning about assigning to parameterRobin Stocker2013-06-151-1/+1
| | | | | | | | | | | | | | | | | | See change I08bed4275af9ec52aa4d7054067ac82f6a3c9781, where fixing such warning lead to complaints. If fixing is not wanted, disable it instead. Change-Id: If31d4028fa1c6377a11e83ed5688b45701cec68b
* | Prepare 3.1.0-SNAPSHOT buildsMatthias Sohn2013-06-132-15/+15
| | | | | | | | | | Change-Id: I7490a7c9558423c03e3c167ad55b9a98be9d99d9 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | Add support for "jgit archive --output=<filename>"Jonathan Nieder2013-06-061-6/+206
| | | | | | | | | | | | | | | | | | | | If the --format option is not given and the output filename is, then infer the format from that filename. Otherwise match "git archive" by defaulting to tar (this is a change from the existing "jgit archive" default behavior, which was to default to zip). Change-Id: I5806bc48a403d05e4cfc3c180b82b33ad7cfae7f
* | Add long filename, large file, and non-ASCII filename support to TarFormatJonathan Nieder2013-06-061-0/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Attempts to write entries with too-long filenames currently error out: $ jgit.pgm/target/jgit archive HEAD >test.tar java.lang.RuntimeException: file name 'org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/resolver/DefaultReceivePackFactory.java' is too long ( > 100 bytes) at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.putArchiveEntry(TarArchiveOutputStream.java:288) at org.eclipse.jgit.archive.TarFormat.putEntry(TarFormat.java:92) at org.eclipse.jgit.archive.TarFormat.putEntry(TarFormat.java:62) at org.eclipse.jgit.api.ArchiveCommand.writeArchive(ArchiveCommand.java:293) at org.eclipse.jgit.api.ArchiveCommand.call(ArchiveCommand.java:322) at org.eclipse.jgit.pgm.Archive.run(Archive.java:97) at org.eclipse.jgit.pgm.TextBuiltin.execute(TextBuiltin.java:174) at org.eclipse.jgit.pgm.Main.execute(Main.java:213) at org.eclipse.jgit.pgm.Main.run(Main.java:121) at org.eclipse.jgit.pgm.Main.main(Main.java:95) That's because the default longFileMode is LONGFILE_ERROR, which throws an exception for filenames longer than 100 characters. Switch to LONGFILE_POSIX. While at it, handle large files and filenames with strange encodings, too. This requires commons compress 1.4, which introduced support for large files and POSIX long filenames. Change-Id: I04d5427eec0968b129f55d7a4c6021039a494828
* | ArchiveCommand: make archive formats non-inner classesJonathan Nieder2013-05-231-0/+7
|/ | | | | | First step toward making ArchiveCommand itself format-agnostic. Change-Id: I3cff5fce28fa7a19e34f8291cfb5b62f16429713
* Move org.eclipse.jgit.pgm's resource bundle to internal packageMatthias Sohn2013-05-062-0/+2
| | | | | | | | Translatable texts aren't API and shouldn't require maintenance of @since tags to prevent API warnings. Change-Id: I228ff37f17c0e792a6bc188c463a0d19138e88ac Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Extend the FS class for Java7Robin Rosenberg2013-05-044-15/+58
| | | | | | | | | | | | | | | | | | | | | The most important difference is that in Java7 we have symbolic links and for most operations in the work tree we want to operate on the link itself rather than the link target, which the old File methods generally do. We also add support for the hidden attribute, which only makes sense on Windows and exists, just since there are claims that Files.exists is faster the File.exists. A new bundle is only activated when run with a Java7 execution environment. It is implemented as a fragment. Tycho currently has no way to conditionally include optional features based on the java version used to run the build, this means with this change the jgit packaging build always needs to be run using java 7. Change-Id: I3d6580d6fa7b22f60d7e54ab236898ed44954ffd Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Fix line endingsMatthias Sohn2013-05-031-79/+79
| | | | Change-Id: I61c9c173237a535da8576a9299bfd4bb29e8f56b Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* status: Print conflict description for unmerged pathsRobin Stocker2013-04-191-3/+3
| | | | | | | Prefix unmerged paths with conflict description (e.g. "both modified:"), the same way C Git does. Change-Id: I083cd191ae2ad3e2460aa4052774aed6e36c2699
* Merge "Remove unused dependencies"Robin Rosenberg2013-04-181-3/+1
|\
| * Remove unused dependenciesMatthias Sohn2013-04-091-3/+1
| | | | | | | | Change-Id: I3cd161ac360a2e2635bffe309725a41c9527694e Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* | Make recursive merge strategy the default merge strategyMatthias Sohn2013-04-151-1/+1
|/ | | | | | | | Use recursive merge as the default strategy since it can successfully merge more cases than the resolve strategy can. This is also the default in native Git. Change-Id: I38fd522edb2791f15d83e99038185edb09fed8e1 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Fix plugin provider names to conform with release train requirementMatthias Sohn2013-04-081-1/+1
| | | | | | | | | | According to release train requirements [1] the provider name for all artifacts of Eclipse projects is "Eclipse <project name>". [1] http://wiki.eclipse.org/Development_Resources/HOWTO/Release_Reviews#Checklist Change-Id: I8445070d1d96896d378bfc49ed062a5e7e0f201f Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Add the no-commit option to MergeCommandTomasz Zarna2013-04-042-3/+36
| | | | | | | | | | Added also tests and the associated option for the command line Merge command. Bug: 335091 Change-Id: Ie321c572284a6f64765a81674089fc408a10d059 Signed-off-by: Christian Halstrick <christian.halstrick@sap.com> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* New functions to facilitate the writing of CLI test casesFrançois Rey2013-03-272-14/+90
| | | | | | | | | | | | Writing CLI test cases is tedious because of all the formatting and escaping subtleties needed when comparing actual output with what's expected. While creating a test case the two new functions are to be used instead of the existing execute() in order to prepare the correct command and expected output and to generate the corresponding test code that can be pasted into the test case function. Change-Id: Ia66dc449d3f6fb861c300fef8b56fba83a56c94c Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* JGit 3.0: move internal classes into an internal subpackageShawn Pearce2013-03-183-14/+14
| | | | | | | | 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
* Prepare 2.4.0-SNAPSHOT buildsMatthias Sohn2013-02-142-13/+13
| | | | | Change-Id: I4ab2baeb5d598d40d5dadfccdfe75152a1b9b7bf Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 2.3.0 buildsMatthias Sohn2012-12-212-13/+13
| | | | | Change-Id: I0ca539e8cfe444f96c64dc56d1f0ef33b66e0cff Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare post 2.2.0.201212191850-r buildsstable-2.2Matthias Sohn2012-12-212-2/+2
| | | | Change-Id: I1a0fe51c71551fcfc98f5dd435eb283fd661b77a Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v2.2.0.201212191850-rv2.2.0.201212191850-rMatthias Sohn2012-12-202-2/+2
| | | | | Change-Id: Idc49f17d03886b6a1e61a94ff81e32625c8675d9 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* archive: Add tar supportJonathan Nieder2012-12-041-7/+160
| | | | | | | | Unlike ZIP files, tar files do not treat symlinks as ordinary files with a different mode, so tar support involves a little more code than would be ideal. Change-Id: Ica2568f4a0e443bf4b955ef0c029bc8eec62d369
* archive: Record executable and symlink bitsJonathan Nieder2012-12-041-0/+74
| | | | | | | | | | | Setting the mode for a zip entry is now as simple as "entry.setUnixMode(mode)", so do that. The test checks using the system's "zipinfo" command (from InfoZIP) that the mode has been recorded correctly on systems that happen to have a "zipinfo" command, using org.junit.Assume to distinguish them. Change-Id: I4236c102fd76f18d01b2dc926eeb9b9fa11a61b7
* Add basic "jgit add" testsJonathan Nieder2012-11-292-0/+116
| | | | | Change-Id: I056c2556c7db98bf57e2527dec11af7c3daf472a Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add "jgit archive" tool that writes a tree as a ZIP fileJonathan Nieder2012-11-161-0/+175
| | | | | | | | | | | | | | | | | | | | | | | C Git's "git archive" command represents a tree object using a standard archival format like tar, zip, or tgz, ready for consumption by other, git-unaware users or tools. Add a bare-bones analagous "jgit archive" command to show what is possible, supporting only ZIP format for now. It uses java.util.zip which is not aware of the InfoZIP extensions for representing symlinks and file permissions, so symlinks, executable files, and submodule entries are represented as plain text files. Making this functionality available from the library, improving handling of special entries, and support for other output formats are left for later patches. Ultimately the intent is to offer a TreeArchiveStream class for use by web frontends like Gitiles to offer "download as zip/tgz/txz" links and use by, for example, code search tools to get easy access to the content of git tree objects. Test with "jgit archive my-favorite-tree >out.zip". Change-Id: Ib590f173ceff3df4b58493cecccd6b9a1b355e3d
* Allow commandline tests to use raw outputJonathan Nieder2012-11-161-4/+11
| | | | | | | | | | | | | | | | | | | | | Introduce a new CLIGitCommand.rawExecute() helper that behaves just like execute() except that instead of processing its output it returns it raw. So now you can do final byte[] expect = { 0, 1, 2, 3 }; final byte[] actual = CLIGitCommand.rawExecute( "git show HEAD:goo.raw", db); assertArrayEquals(expect, actual); to test the output from "git show HEAD:goo.raw" without being distracted by encoding issues. Noticed while writing tests for a new "jgit archive" command that writes its output in ZIP format. Change-Id: I2fe6020a537975d0ccf414b7125d85d6cd86898c
* Add reflog command to JGit CLITomasz Zarna2012-11-161-0/+80
| | | | | | Bug: 394497 Change-Id: Ib8bc1d9fd789d22fe5f10e03068a11cfdd3e46eb Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Harmonize the JDT settings within JGitRobin Rosenberg2012-11-163-7/+81
| | | | | | | | | | | Note the the settings are slightly less restrictive for test bundles. -Also cleanup a couple of malformed javadocs -Update compiler warnings/errors to include default values from Juno -We now flag diagnosed null dereference as error. We didn't do that earlier because of some false positives. Change-Id: I58386d63164e65d3d8d1998da3390d99bdc7381a Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add support for --no-ff while mergingTomasz Zarna2012-11-161-2/+57
| | | | | | Bug: 394432 Change-Id: I373128c0ba949f9b24248874f77f3d68b50ccfd1 Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Add a test for org.eclipse.jgit.pgm.TagTomasz Zarna2012-11-151-0/+73
| | | | | | | | The test checks if an error is thrown when trying to create the same tag for the second time. Change-Id: I4ed2f6c997587f0ea23bd26a32fb64a2d48a980e Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Do not fail when checking out HEADTomasz Zarna2012-11-151-3/+20
| | | | | Change-Id: I99f5467477ed53101121a5a5d8a0910c55758401 Signed-off-by: Chris Aniszczyk <zx@twitter.com>
* Prefix an abnormal CLI command termination with 'fatal:'Tomasz Zarna2012-11-153-4/+6
| | | | | Change-Id: I3d257666c6fbed7b238c575808f73ec518e811b9 Signed-off-by: Chris Aniszczyk <zx@twitter.com>