Commit Graph

26 Commits (b72e0f71e532930d529ba92e7e210eea1c1ae2ae)

Author SHA1 Message Date
Thomas Keller 473e9153ed Merge branch 'develop' into feature.diff-whitespace 2011-10-09 01:40:59 +02:00
Thomas Keller efa10c9afd Properly quote file names for the system call. 2011-10-09 01:39:05 +02:00
Thomas Keller d0e2977746 Add support for line ending detection in our diff parser.
Line endings are now preserved during the diff parsing. When the diff
is then rendered later on, we replace non-printable characters by their
ordinal counterparts, so a user can easily grasp changes when a hunk
comes with edits that might be invisible at first.

The expected format for the diff test suite has changed from serialized
PHP to var_export, which is easier readable, editable and understandable,
while still keeping parsable as well.

Support for old Macintosh line endings could not be added, mainly because
modern SCMs do not support single \r in their unified diff output either
and working around and parsing these "lines" would have been a major
headache with not much outcome (given the fact that all Macs that have been
sold since 2001 or 2002 have been BSD-based and as such used Unix line
endings by default).

This commit fixes issue 636.
2011-10-05 02:44:04 +02:00
Thomas Keller b1b72190e1 Dropped a few more not needed files. 2011-08-13 01:19:58 +02:00
Thomas Keller 2ff2f888bc - Make the SVN test case work without specific test configuration.
- Rename the test repo to match the test function so we can create
  more test repositories for other tests at a later stage.
- Remove useless hooks and configs from the repo (they are not used
  for our specific test and just need memory).
- Note the fix for issue 721 in NEWS.mdtext.
2011-08-13 01:11:00 +02:00
Patrick Georgi 57c2389aae Make SVN backend more robust
The SVN backend failed when trying to access historical information on deleted files.

There's also an initial test case for the SVN backend, testing this issue
and issue 364, which is about a similar problem for renamed files.
Reverting any of these fixes breaks the test.
2011-08-12 20:53:26 +02:00
William MARTIN 9bbcd571ec Merge branch 'feature.issue-summary' into develop 2011-06-20 11:37:26 +02:00
William MARTIN bbc185bf3b Add unit test for IDF_Project::getIssueCountByOwner 2011-06-20 11:34:42 +02:00
Thomas Keller d1bcdcda20 Fix the mtn getChanges() test. 2011-06-17 23:50:35 +02:00
Thomas Keller ca2ef814fb Add support for the display of monotone node attributes.
(also fix the way the attributes view is displayed, i.e. do not
 use single strings, but one string in context which is much easier
 to translate)
2011-05-31 13:11:55 +02:00
Thomas Keller 801af66a4e Apparently header() does kind of work for php-cli, but of course breaks horribly.
Luckily Pluf has a little knob (IN_UNIT_TESTS) that can prevent this breakage.
2011-04-19 11:07:58 +02:00
Thomas Keller df6ffdf420 Three more test cases for the mtn interface added
- add tests for getTree(), getChanges() and isCommitLarge()
- anonymize the test data somewhat
- return false instead of null for unknown revisions given to getChanges()
2011-04-15 00:54:11 +02:00
Thomas Keller b3368071ac Continue with the mtn interface tests
- test getRepositorySize() with a test file
- implement tests for inTags(), inBranches(), getFile(),
  getCommit() and getExtraProperties()
- mark the static methods as untestable
2011-04-14 00:48:36 +02:00
Thomas Keller 67b80ee11c Continue with the mtn interface tests
- getPathInfo(), disambiguateRevision() and validateRevision() are done
- we no longer need to check / skip a format_version stanza for the extended
  manifest (there is no such stanza outputted)
2011-04-12 23:47:44 +02:00
Thomas Keller 29c7fed81b Merge branch 'develop' of git://projects.ceondo.com/indefero into develop 2011-04-06 03:01:40 +02:00
Thomas Keller fb62061e5a Started with a unit test for the monotone interface.
Main test infrastructure is there, still lots of functionality left
for testing. Fixed a possible bug in the SCM interface already:
Pluf_HTTP_Response_NotFound needs a request instance as ctor argument,
which we don't have at this point, therefor we just throw an exception.
2011-04-06 02:59:26 +02:00
William MARTIN 5ea4b02205 Update copyrigt 2011-04-02 21:37:07 +02:00
Thomas Keller 766232f29b Add missing license header. 2011-03-30 00:00:22 +02:00
Thomas Keller 30900f7196 monotone zip archive entries now all carry the revision date as mtime (issue 645);
add a test case for the zip render response that works with and without PHP's
zip extension
2011-03-24 23:54:52 +01:00
Thomas Keller b753cf0837 Fix a coment. 2011-03-24 01:19:05 +01:00
Thomas Keller 53ab5b6aff Expand the bootstrap script to setup an empty IDF environment. 2011-03-24 00:41:22 +01:00
Thomas Keller 5b5705fe90 Add a unit test for monotone's basicio parser and compiler.
Also note a couple of quirks and be less strict (for now) when it
comes to hash parsing and stanza lines without values.
2011-03-23 00:26:26 +01:00
Thomas Keller 5a7bf49cbb Well, I forgot the important stuff in the last commit, sigh. Fixes issue 633 for real now. 2011-03-18 01:05:25 +01:00
Thomas Keller a3dd1c45f3 Handle partial incomplete and line-ending munging diffs (resolves issue 633). 2011-03-18 00:55:02 +01:00
Thomas Keller 51dde5766d Add a test case for issue 633. 2011-03-17 01:58:01 +01:00
Thomas Keller 61d7b4a58d Setup a basic PHPUnit test environment.
To run all available tests its enough to call

 $ phpunit

from the root workspace directory; the default phpunit configuration
resides in phpunit.xml. A bootstrap script sets some default paths
and can be extended later on with other useful stuff.

Each test class' path should mimic the name and path of the source
class, only that the test class gets an additional "Test" appended so
PHPUnit can find it automatically. The data directory can be used
in a flat manner; for tests that need test data a separate directory
containing these files should be added, and the directory should be
named after the test class itself.

The first test which uses the new infrastructure is a test for the
rewritten diff parser (closes issue 627).
2011-03-17 01:12:32 +01:00