#
# add_file "tests/README"
#
# add_file "tests/t_cvsimport2.at"
#
# add_file "tests/t_lf_crlf.at"
#
# add_file "tests/t_rcs_import.at"
#
# add_file "tests/t_rename_dir_add_dir_with_old_name.at"
#
# patch ".mt-attrs"
# from [f9b65d9f157beb7932b20e4a85eb65487949ade9]
# to [d916e2d789f2c0f4e92f983099b16ec904a2379b]
#
# patch "AUTHORS"
# from [97910e402895c8bbae9ad72fad2e58c9f8965508]
# to [e3730a36bbd3ebd44b05f6d93750bb83022d5572]
#
# patch "ChangeLog"
# from [fc29b1b0e56094bb18cc92c8d8f8cac560d98dd0]
# to [3ab04183dd540cb0209d59b6a945d2c98a91fcff]
#
# patch "change_set.cc"
# from [f45da9e6d6bc784324d6f606a12d21c34a6f306d]
# to [8721281fd257c827409baf2df2ec98e7883e0710]
#
# patch "contrib/README"
# from [6d1db875fa3a286389a8c19eee3b19bf1772a3d6]
# to [41748f8afac99a87841c3f94004bbfc6f4295611]
#
# patch "monotone.1"
# from [7ce55a7b2b6ec659e94edd7947ee9ce6c62053e1]
# to [9a00ecadd333fe803fe4788d579afb75f3a8aa51]
#
# patch "monotone.texi"
# from [82e309cffe8832da1e871c00c9795af49531f1df]
# to [31fabd3d2cdf017dfc5af29af363dbd9e6f74c21]
#
# patch "tests/README"
# from []
# to [fdbb3d9f63642092343e0ea58b7ee937f910103a]
#
# patch "tests/t_cvsimport2.at"
# from []
# to [4641874ff2fbedf55b84c1169dd86e4d2354c36b]
#
# patch "tests/t_diff_binary.at"
# from [651f781bf58848169446baee444f3f1418b7b24f]
# to [de45d9dca34e5765bd998968752d25368c8238e1]
#
# patch "tests/t_lf_crlf.at"
# from []
# to [5c7f37f18e1ae4e195a4f7581145705d390e1747]
#
# patch "tests/t_rcs_import.at"
# from []
# to [a77bf74fb559cc91d3167022f6595e2fb471bac4]
#
# patch "tests/t_rename_dir_add_dir_with_old_name.at"
# from []
# to [b005c1839d019fa629d02fa1373f391715937594]
#
# patch "testsuite.at"
# from [14b8600c48fdafc19eba6942e2270738b4bd8c71]
# to [d2d93700980437bc4d42f041d1d088c06b4e5200]
#
--- .mt-attrs
+++ .mt-attrs
@@ -1,4 +1,4 @@
- file "contrib/Notify.pl"
+ file "contrib/monotone-notify.pl"
execute "true"
file "contrib/ciabot_monotone.py"
--- AUTHORS
+++ AUTHORS
@@ -52,6 +52,8 @@
Jon Bright
Corey Halpin
Jeremy Cowgar
+ Martin Dvorak
+ Emile Snyder
supporting files:
--- ChangeLog
+++ ChangeLog
@@ -1,19 +1,86 @@
2005-04-17 Matthew Gregan
* monotone.cc: Fix warnings: add missing initializers.
* netsync.cc: Fix warnings: inline static vs static inline.
-2005-04-15 Sebastian Spaeth
+2005-04-16 Nathaniel Smith
- * ui.cc: print byte progress to one decimal place
- in k or M.
- * netsync.cc: update dot ticker every 1024 bytes.
+ * testsuite.at: Use a random server port.
+
+ * .mt-attrs, contrib/README: Update for Notify.pl ->
+ monotone-notify.pl rename.
+
+ * monotone.1: Warn people off rcs_import.
+ * monotone.texi (Commands): Likewise.
+2005-04-16 Nathaniel Smith
+
+ * AUTHORS: Add Emile Snyder .
+
+2005-04-16 Nathaniel Smith
+
+ * tests/t_lf_crlf.at: New test from Emile Snyder
+ , with tweaks.
+ * testsuite.at: Add it.
+
+2005-04-16 Nathaniel Smith
+
+ * ChangeLog: Small fixups.
+
+2005-04-16 Sebastian Spaeth
+
+ * tests/t_cvsimport2.at: new test; CVS Attic files fail test
+ reported by: address@hidden 15.04.2005 02:45
+
+2005-04-16 Sebastian Spaeth
+
+ * tests/t_rcs_import.at: new test; problematic CVS import as
+ reported in the list. However it works just fine here, so it
+ really tests for a successful pass
+
+2005-04-16 Sebastian Spaeth
+
+ * tests/README: new file, on how to create/run tests
+
+2005-04-16 Nathaniel Smith
+
+ * tests/t_rename_dir_add_dir_with_old_name.at: XFAIL.
+
+2005-04-16 Nathaniel Smith
+
+ * tests/t_diff_binary.at: Un-XFAIL.
+
+2005-04-16 Nathaniel Smith
+
+ * monotone.texi (Network Service): Rewrite to include former
+ Exchanging Keys section.
+ (Branching and Merging): New tutorial section, inspired by a patch
+ from Martin Kihlgren .
+ (CVS Phrasebook): Add "Importing a New Project".
+
+ * AUTHORS: Add Martin Dvorak.
+
+2005-04-15 Martin Dvorak
+
+ * tests/t_rename_dir_add_dir_with_old_name.at: New test.
+ * testsuite.at: Add it.
+
+2005-04-16 Matt Johnston
+
+ * change_set.cc (compose_rearrangement): remove logging statements
+ that were using noticable CPU time.
+
2005-04-15 Olivier Andrieu
* diff_patch.cc(guess_binary): do not use '\x00' as first
character of a C string ...
+2005-04-15 Sebastian Spaeth
+
+ * ui.cc: print byte progress to one decimal place
+ in k or M.
+ * netsync.cc: update dot ticker every 1024 bytes.
+
2005-04-15 Matt Johnston
* change_set.cc (confirm_proper_tree): use bitsets rather than maps
--- change_set.cc
+++ change_set.cc
@@ -761,15 +761,19 @@
if (old_path == new_path)
{
+ /*
L(F("skipping preserved %s %d : '%s'\n")
% (path_item_type(old_item) == ptype_directory ? "directory" : "file")
% curr % old_path);
+ */
continue;
}
+ /*
L(F("analyzing %s %d : '%s' -> '%s'\n")
% (path_item_type(old_item) == ptype_directory ? "directory" : "file")
% curr % old_path % new_path);
+ */
if (null_name(path_item_name(old_item)))
{
--- contrib/README
+++ contrib/README
@@ -5,8 +5,8 @@
-- Log2Gxl.java: Java code to convert output from 'monotone log' into
GXL, an XML-based graph description language.
- -- Notify.pl: a Perl hack to create email logs with recent changes
- in a repository database. It's designed to be run at regular
+ -- monotone-notify.pl: a Perl hack to create email logs with recent
+ changes in a repository database. It's designed to be run at regular
intervals, for example from a cron script. It uses database
variables (those handled with 'monotone set/unset') in the domain
domain 'notify' to keep track of the last revisions that have
--- monotone.1
+++ monotone.1
@@ -114,7 +114,8 @@
.TP
\fBrcs_import\fP \fI ...\fP
Import all file versions in RCS files. Does not reconstruct revisions
-across the entire tree.
+across the entire tree. You do not want this command, it is for
+debugging; use cvs_import.
.TP
\fBcheckout\fP \fI[manifest-id]\fP \fI~/jim.pubkey
address@hidden group
address@hidden smallexample
-
-His public key is just a plain block of ASCII text:
-
address@hidden
address@hidden
-$ cat ~/jim.pubkey
-[pubkey jim@@juicebot.co.jp]
-MIGdMA0GCSqGSIb3DQEBAQUAA4GLADCBhwKBgQCbaVff9SF78FiB/1nUdmjbU/TtPyQqe/fW
-CDg7hSg1yY/hWgClXE9FI0bHtjPMIx1kBOig09AkCT7tBXM9z6iGWxTBhSR7D/qsJQGPorOD
-DO7xovIHthMbZZ9FnvyB/BCyiibdWgGT0Gtq94OKdvCRNuT59e5v9L4pBkvajb+IzQIBEQ==
-[end]
address@hidden group
address@hidden smallexample
-
-Abe also exports his public key:
-
address@hidden
address@hidden
-$ monotone --db=~/abe.db pubkey abe@@juicebot.co.jp >~/abe.pubkey
address@hidden group
address@hidden smallexample
-
-As does Beth:
-
address@hidden
address@hidden
-$ monotone --db=~/beth.db pubkey beth@@juicebot.co.jp >~/beth.pubkey
address@hidden group
address@hidden smallexample
-
-Then all three team members exchange keys. The keys are not secret,
-but the team members must be relatively certain that they are
-communicating with the person they intend to trust, when exchanging
-keys, and not some malicious person pretending to be a team
-member. Key exchange may involve sending keys over an encrypted
-medium, or meeting in person to exchange physical copies, or any
-number of techniques. All that matters, ultimately, is for each team
-member to receive the keys of the others.
-
-So eventually, after key exchange, Jim has Beth's and Abe's public key
-files in his home directory, along with his own. He tells monotone to
-read the associated key packets into his database:
-
address@hidden
address@hidden
-$ monotone --db=~/jim.db read <~/abe.pubkey
-monotone: read 1 packet
-$ monotone --db=~/jim.db read <~/beth.pubkey
-monotone: read 1 packet
address@hidden group
address@hidden smallexample
-
-Beth and Abe similarly tell monotone to read read the two new public
-keys they received into their respective databases.
-
-
address@hidden
@node Starting a New Project
@section Starting a New Project
-Before they can begin work on the project, Jim needs to create a
+Before he can begin work on the project, Jim needs to create a
@i{working copy} --- a directory whose contents monotone will keep track
of. Often, one works on projects that someone else has started, and
creates working copies with the @code{checkout} command, which you'll
@@ -1529,10 +1457,7 @@
@smallexample
@group
$ monotone --db=jim.db --branch=jp.co.juicebot.jb7 commit --message='initial checkin of project'
-monotone: beginning commit
-monotone: manifest 2098eddbe833046174de28172a813150a6cbda7b
-monotone: revision 2e24d49a48adf9acf3a1b6391a080008cbef9c21
-monotone: branch jp.co.juicebot.jb7
+monotone: beginning commit on branch 'jp.co.juicebot.jb7'
monotone: committed revision 2e24d49a48adf9acf3a1b6391a080008cbef9c21
@end group
@end smallexample
@@ -1643,12 +1568,68 @@
@section Network Service
Jim now decides he will make his base revision available to his
-employees. To do this first adds a small amount of extra information
-to his @file{.monotonerc} file, permitting Abe and Beth to access his
-database:
+employees. To do this he gives Abe and Beth permission to access his
+database. There are two parts to this: first, he has to get a copy of
+each of their public keys; then, he has to tell monotone that the
+holders of those keys are permitted to access his database.
+First, Abe exports his public key:
+
@smallexample
@group
+$ monotone --db=~/abe.db pubkey abe@@juicebot.co.jp >~/abe.pubkey
address@hidden group
address@hidden smallexample
+
+His public key is just a plain block of ASCII text:
+
address@hidden
address@hidden
+$ cat ~/abe.pubkey
+[pubkey abe@@juicebot.co.jp]
+MIGdMA0GCSqGSIb3DQEBAQUAA4GLADCBhwKBgQCbaVff9SF78FiB/1nUdmjbU/TtPyQqe/fW
+CDg7hSg1yY/hWgClXE9FI0bHtjPMIx1kBOig09AkCT7tBXM9z6iGWxTBhSR7D/qsJQGPorOD
+DO7xovIHthMbZZ9FnvyB/BCyiibdWgGT0Gtq94OKdvCRNuT59e5v9L4pBkvajb+IzQIBEQ==
+[end]
address@hidden group
address@hidden smallexample
+
+Beth also exports her public key:
+
address@hidden
address@hidden
+$ monotone --db=~/beth.db pubkey beth@@juicebot.co.jp >~/beth.pubkey
address@hidden group
address@hidden smallexample
+
+Then Abe and Beth both send their keys to Jim. The keys are not secret,
+but the team members must be relatively certain that they are
+communicating with the person they intend to trust, when exchanging
+keys, and not some malicious person pretending to be a team
+member. Key exchange may involve sending keys over an encrypted
+medium, or meeting in person to exchange physical copies, or any
+number of techniques. All that matters, ultimately, is that Jim receive
+both Abe and Beth's key.
+
+So eventually, after key exchange, Jim has the public key files in his
+home directory. He tells monotone to read the associated key packets
+into his database:
+
address@hidden
address@hidden
+$ monotone --db=~/jim.db read <~/abe.pubkey
+monotone: read 1 packet
+$ monotone --db=~/jim.db read <~/beth.pubkey
+monotone: read 1 packet
address@hidden group
address@hidden smallexample
+
+Now Jim's monotone is able to identify Beth and Abe, and he is ready to
+give them permission to access his database. He does this by adding a
+small amount of extra information to his @file{.monotonerc} file:
+
address@hidden
address@hidden
$ cat >>~/.monotonerc
function get_netsync_read_permitted (collection, identity)
if (identity == "abe@@juicebot.co.jp") then return true end
@@ -1719,8 +1700,9 @@
always running; this way, everyone always knows where to go to get the
latest changes, and people can push their changes out without first
calling their friends and making sure that they have their servers
-running. To support this style of working, monotone remembers the first
-server you use, and makes that the default for future operations.
+running. To make this style of working more convenient, monotone
+remembers the first server you use, and makes that the default for
+future operations.
@page
@node Making Changes
@@ -1785,10 +1767,8 @@
@smallexample
@group
$ monotone commit
-monotone: beginning commit
-monotone: manifest b33cb337dccf21d6673f462d677a6010b60699d1
-monotone: revision 70decb4b31a8227a629c0e364495286c5c75f979
-monotone: branch jp.co.juicebot.jb7
+monotone: beginning commit on branch 'jp.co.juicebot.jb7'
+monotone: commited revision 70decb4b31a8227a629c0e364495286c5c75f979
@end group
@end smallexample
@@ -1894,10 +1874,7 @@
@smallexample
@group
$ monotone commit
-monotone: beginning commit
-monotone: manifest eaebc3c558d9e30db6616ef543595a5a64cc6d5f
-monotone: revision 80ef9c9d251d39074d37e72abf4897e0bbae1cfb
-monotone: branch jp.co.juicebot.jb7
+monotone: beginning commit on branch 'jp.co.juicebot.jb7'
monotone: committed revision 80ef9c9d251d39074d37e72abf4897e0bbae1cfb
@end group
@end smallexample
@@ -2012,10 +1989,7 @@
@smallexample
@group
$ monotone commit --message='interrupt implementation of src/banana.c'
-monotone: beginning commit
-monotone: manifest de81e46acb24b2950effb18572d5166f83af3881
-monotone: revision 8b41b5399a564494993063287a737d26ede3dee4
-monotone: branch jp.co.juicebot.jb7
+monotone: beginning commit on branch 'jp.co.juicebot.jb7'
monotone: committed revision 8b41b5399a564494993063287a737d26ede3dee4
@end group
@end smallexample
@@ -2126,6 +2100,95 @@
step) and your committed state is still safe. It is therefore
recommended that you commit your work @emph{first}, before merging.
address@hidden
address@hidden Branching and Merging
address@hidden Branching and Merging
+
+So by now you're familiar with making changes, sharing them with other
+people, and integrating your changes with their changes. Sometimes,
+though, you may want to make some changes, and @emph{not} integrate them
+with other people's --- or at least not right away. One way to do this
+would be to simply never run @command{monotone merge}; but it would
+quickly become confusing to try and keep track of which changes were in
+which revisions. This is where @emph{branches} are useful.
+
+Continuing our example, suppose that Jim is so impressed by Beth's work
+on banana juice support that he assigns her to work on the JuiceBot 7's
+surprise new feature: muffins. In the mean time, Abe will continue
+working on the JuiceBot's basic juice-related function.
+
+The changes required to support muffins are somewhat complicated, and
+Beth is worried that her work might destabilize the program, and
+interfere with Abe's work. In fact, she isn't even sure her first
+attempt will turn out to be the right approach; she might work on it for
+a while and then decide it was a bad idea, and should be discarded. For
+all these reasons, she decides that she will work on a branch, and then
+once she is satisfied with the new code, she will merge back onto the
+mainline.
+
+She decides that since main development is in branch
address@hidden, she will use branch
address@hidden So, she makes the first few edits to
+the new muffins code, and commits it on a new branch by simply passing
address@hidden to commit:
+
address@hidden
address@hidden
+$ monotone commit --branch=jp.co.juicebot.jb7.muffins --message='initial autobake framework'
+monotone: beginning commit on branch 'jp.co.juicebot.jb7.muffins'
+monotone: committed revision d33caefd61823ecbb605c39ffb84705dec449857
address@hidden group
address@hidden smallexample
+
+That's all there is to it --- now there is a
address@hidden branch, with her initial checkin on
+it. She can make further checkins from the same working copy, and they
+will automatically go to the muffins branch; if anyone else wants to
+help her work on muffins, they can check out that branch as usual.
+
+Of course, while Beth is working on the new muffins code, Abe is still
+making fixes to the main line. Occasionally, Beth wants to integrate
+his latest work into the muffins branch, so that her version doesn't
+fall too far behind. She does this by using the @command{propagate}
+command:
+
address@hidden
address@hidden
+$ monotone propagate jp.co.juicebot.jb7 jp.co.juicebot.jb7.muffins
+monotone: propagating jp.co.juicebot.jb7 -> jp.co.juicebot.jb7.muffins
+monotone: [source] da003f115752ac6e4750b89aaca9dbba178ac80c
+monotone: [target] d0e5c93bb61e5fd25a0dadf41426f209b73f40af
+monotone: common ancestor 853b8c7ac5689181d4b958504adfb5d07fd959ab found
address@hidden group
address@hidden smallexample
+
+The @command{propagate} merges all of the new changes on one branch onto
+another.
+
+When the muffins code is eventually stable and ready to be integrated
+into the main line of development, she simple propagates the other way:
+
address@hidden
address@hidden
+$ monotone propagate jp.co.juicebot.jb7.muffins jp.co.juicebot.jb7
+monotone: propagating jp.co.juicebot.jb7 -> jp.co.juicebot.jb7.muffins
+monotone: [source] 4e48e2c9a3d2ca8a708cb0cc545700544efb5021
+monotone: [target] bd29b2bfd07644ab370f50e0d68f26dcfd3bb4af
+monotone: common ancestor 652b1035343281a0d2a5de79919f9a31a30c9028 found
address@hidden group
address@hidden smallexample
+
+Monotone always records the full history of all merges, and is designed
+to handle an arbitrarily complicated graph of changes. You can make a
+branch, then branch off from that branch, propagate changes between
+arbitrary branches, and so on; monotone will track all of it, and do
+something sensible for each merge. Of course, it is still probably a
+good idea to come up with some organization of branches and a plan for
+which should be merged to which other ones. Monotone may keep track of
+graphs of arbitrary complexity; but, you will have more trouble.
+Whatever arrangement of branches you come up with, though, monotone
+should be able to handle it.
+
@node Advanced Uses
@chapter Advanced Uses
@@ -2942,7 +3005,7 @@
@tab
@smallexample
@group
-$ monotone diff 3e7db 278df
+$ monotone diff -r 3e7db -r 278df
@end group
@end smallexample
@end multitable
@@ -3024,6 +3087,29 @@
manifest of the current revision.
address@hidden Importing a New Project
+
address@hidden @columnfractions .4 .4
address@hidden
address@hidden
address@hidden
+$ cvs import wobbler vendor start
address@hidden group
address@hidden smallexample
address@hidden
address@hidden
address@hidden
+$ monotone --db=/path/to/database.db --branch=com.foo.wobbler setup .
+$ monotone add .
+$ monotone commit
address@hidden group
address@hidden smallexample
address@hidden multitable
+
+The @command{setup} command turns an ordinary directory into a
+monotone working copy. After that, you can add your files and commit
+them as usual.
+
@heading Initializing a Repository
@multitable @columnfractions .4 .4
@@ -5763,7 +5849,8 @@
@item @b{rcs_import} @i{ ...}
Import all file versions in RCS files. Does not reconstruct revisions
-across the entire tree.
+across the entire tree. You do not want this command, it is for
+debugging; use cvs_import.
@comment TROFF INPUT: .TP
@item @b{checkout} @i{[manifest-id]} @i{}
--- tests/README
+++ tests/README
@@ -0,0 +1,48 @@
+HOWTO make tests
+================
+
+Quick and dirty howto, to get you up to create and run tests.
+Very early draft. Feel free to improve.
+
+Running tests:
+--------------
+- Starting in the monotone main dir. After having './configure'd monotone you
+ can do 'make testsuite' to create 'testsuite'. Running './testsuite' will
+ run all tests.
+- 'testsuite -l' lists the names and numbers of all available tests
+- 'testsuite ' runs only test number n
+- option -v will show the command outputs
+- option -d will keep the testsuite.dir files for post-test debugging
+- option -h is your friend :)
+
+Creating tests:
+---------------
+- Copy and paste is your friend :)
+- TODO: need more here...
+
+
+Template for a test (name t_.at
+-------------------
+
+AT_SETUP([brief test description goes here])
+MONOTONE_SETUP
+
+#the next lines (including AT_XFAIL_IF) state that the test is
+#expected to fail as this is still a bug. Remove if it should pass!
+# This test is a bug report. It is expected to fail
+AT_XFAIL_IF(true)
+
+#AT_CHECK executes a shell command, second argument is the error
+#return code we expect, third argument is the output we expect from
+#stdout. use ignore if you don't care about the output. If oyu use
+#stdout all following commands can use file 'stdout' for further
+#processing. Same goes with 'stderr' as the last argument
+#see autoconf tutorials
+#e.g. http://www.gnu.org/software/autoconf/manual/autoconf-2.57/
+# html_node/autoconf_167.html for further information.
+AT_CHECK(MONOTONE import foo, [], ignore, ignore)
+...
+...
+...
+AT_CLEANUP
+(END)
--- tests/t_cvsimport2.at
+++ tests/t_cvsimport2.at
@@ -0,0 +1,41 @@
+AT_SETUP([test failing cvs import (Attic)])
+MONOTONE_SETUP
+
+# This test imports a cvs archive with files in the Attic which fails
+#monotone: fatal: std::logic_error: change_set.cc:2546: invariant 'I(b.rearrangement.deleted_files.empty())' violated
+
+# reported by: address@hidden 15.04.2005 02:45
+# This test is a bug report.
+AT_XFAIL_IF(true)
+
+AT_DATA(prepare.sh,[#!/bin/sh
+export CVSROOT=$PWD/cvsroot
+
+cvs init
+mkdir src
+echo FOO > src/foo
+(
+ cd src
+ cvs import -m import mod vtag rtag
+)
+rm -rf src
+
+mkdir src
+(
+ cd src
+ cvs co mod
+ cd mod
+ cvs tag -b branch
+ cvs up -r branch
+ echo BAR > bar
+ cvs add bar
+ cvs ci -m 'add bar'
+)
+])
+
+AT_CHECK(sh prepare.sh, [], ignore, ignore)
+
+AT_CHECK(MONOTONE --branch=test cvs_import ., [], ignore, ignore)
+
+AT_CLEANUP
+(END)
--- tests/t_diff_binary.at
+++ tests/t_diff_binary.at
@@ -1,10 +1,7 @@
AT_SETUP([diff a binary file])
MONOTONE_SETUP
NEED_UNGZB64
-# This test is a bug report.
-AT_XFAIL_IF(true)
-
# diff should probably not display the contents of binary files
AT_DATA(binary.gz.b64,
--- tests/t_lf_crlf.at
+++ tests/t_lf_crlf.at
@@ -0,0 +1,44 @@
+AT_SETUP([use get_linesep_conv hook])
+MONOTONE_SETUP
+NEED_UNB64
+
+# This test is a bug report.
+AT_XFAIL_IF(true)
+
+# This test excercises the common case of wanting to do newline
+# character conversion so that win32 users can have native line endings
+# in their working copies.
+
+
+# wrote files with 'foo\r\n' and 'foo\r\nfoo\r\n' and used mimencode
+# to generate the following b64 encoded contents.
+#
+# Note the newline before the closing ']', it's necessary.
+#
+AT_DATA(foo.lfcr.b64, [Zm9vDQo=
+])
+AT_DATA(foofoo.lfcr.b64, [Zm9vDQpmb28NCg==
+])
+
+UNB64(foo.lfcr.b64, foo.lfcr)
+UNB64(foofoo.lfcr.b64, foofoo.lfcr)
+
+AT_DATA(linesep.lua, [
+function get_linesep_conv(name)
+ return {"LF", "CRLF"}
+end
+])
+
+AT_CHECK(cp foo.lfcr foo, [], [ignore], [ignore])
+AT_CHECK(MONOTONE --rcfile=linesep.lua add foo, [], [ignore], [ignore])
+AT_CHECK(MONOTONE --rcfile=linesep.lua --branch=foo commit -m foo, [], [ignore], [ignore])
+FOO_REV=`BASE_REVISION`
+
+AT_CHECK(cp foofoo.lfcr foo, [], [ignore], [ignore])
+AT_CHECK(MONOTONE --rcfile=linesep.lua commit -m foofoo, [], [ignore], [ignore])
+FOO_FOO_REV=`BASE_REVISION`
+
+AT_CHECK(MONOTONE --rcfile=linesep.lua update $FOO_REV, [], [ignore], [ignore])
+AT_CHECK(cmp foo foo.lfcr, [], [ignore], [ignore])
+
+AT_CLEANUP
--- tests/t_rcs_import.at
+++ tests/t_rcs_import.at
@@ -0,0 +1,190 @@
+AT_SETUP([test problematic cvs import])
+MONOTONE_SETUP
+NEED_UNGZB64
+
+# This test imports a rcs file which fails according to the mailing list
+# reporter: Carl Christian Kanne "Bug? in CVS import monotone 0.18"
+# Date: Fri, 15 Apr 2005 12:53:13 +0200
+# However when I test it, it succeeds---> examine
+# This test is a bug report.
+#AT_XFAIL_IF(true)
+
+# This rcs file fails to be imported correctly by monotone
+
+AT_DATA(rcsfile.gz.b64, [
+H4sICKQRYUIAA2hhc2h0YWJsZS5oaCx2AMRce3PbNrb/2/wUqNvptR1b4lMvt13n4W29k8SZxG3v
+bKfjoUXIYi2RWpKy4u7kfvY95wAgAYqipCY71ztVbAI8AM7zd86BdsrD6MDpuM65FY7HPM/Prfxp
+fpfOcutgFkf5CMc6dse1DpKwiD+eubf2rX22yHgPhpyB8bj+BKf5+NCrPfTkw8eYrz7OZ/l4yuch
+POvBSr51MImzvMj4OH3k2RM8DuBxzzq4ufxwc/nqNozC7CHMbl3bdhzb6dme08dJmyb4tmf32iZ4
+MKGVggtLDNsmONso2Fv2YA+3TRhsWcLub5sAjLIHbROCbRR8x/GctgkgCX8zBXvg4jG9tgmDig/h
+3TJ/uo34I5/dznl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uflFlVgr8jIEO
+ak+5JxLQHwz1ggg0NryXGmyljFjlRRTEYgxWvJ7kDNJJeCslm1EKJoZJlEVLTKLloKhwESoulkMS
+S3IkzxksQNRnCosHD/jzFB7HzdiUrZo/C0yXvsZPkcayi8c2M1PRg18GlURIwRs/BOLLJR7DLrWS
+eV0fN7LD5KQr656nN5C4Twidx1BOCBL21Hy/++6OTKMJKNRIYYlqS2IE5rHvo+wHMHgMZwJRVVVU
+LH7+wdBiEG3dTHMFwA9DaqFeNv002woITN0oJoqNtpxpTrTxu3K9bEPVCbuxq+GbbRJw05YkT1g7
+D56T/Myh7drIMOwhUxvME4IeFWXFuJf61OyClQ/LezIXPSoPh637s/CoPDE8Cp/RuqgbIwh11IdE
+aZ3qrJGKGmuorj9OH/mjdeNEpCPSPCOqEVHZROuI9MRpfUIrTD9KHTD9Fh/JtMFEv0s/p9pcRMIS
+3S39JjS1iLgJvWzslaFAQ9/zhk4bTzSwSGOa6FsM0U7ba1tZTpzk9lFz9GoSZ8QpjJSqWKdCuAJT
+32qJER3kQykbijbRMhdaZkKHeNAiC1riQJIBNWBAkbpHI0iYT0NBZWPZkRbKscA6xEG+Iu07fqLH
+CLUwj5VO9vaYV1T5MVjKpiqGJlZWNHwVmMxDMZs4HJPGUWM4Lf6FwWmzx+in5EStkKjxrwr/qump
+NksYX3riaBmsp4m/Pv0ZR559DrmcAAA=
+])
+
+AT_CHECK(mkdir tmp, [], stdout, ignore)
+UNGZB64(rcsfile.gz.b64, tmp/rcsfile,v)
+
+AT_CHECK(MONOTONE --branch=test cvs_import tmp, [], ignore, ignore)
+
+AT_CLEANUP
+(END)
--- tests/t_rename_dir_add_dir_with_old_name.at
+++ tests/t_rename_dir_add_dir_with_old_name.at
@@ -0,0 +1,28 @@
+# -*- Autoconf -*-
+
+AT_SETUP([renaming a directory and then adding a new with the old name])
+
+MONOTONE_SETUP
+
+# This test is a bug report.
+AT_XFAIL_IF(true)
+
+# add 'foo/test' file
+AT_CHECK(mkdir foo)
+AT_DATA(foo/test, [test file in foo dir
+])
+AT_CHECK(MONOTONE add foo, [], [ignore], [ignore])
+COMMIT(testbranch)
+
+# rename 'foo' dir to 'bar'
+AT_CHECK(MONOTONE rename foo bar, [], [ignore], [ignore])
+AT_CHECK(mv foo bar)
+
+# add new 'foo' dir
+AT_CHECK(mkdir foo)
+AT_DATA(foo/test, [test file in new foo dir
+])
+AT_CHECK(MONOTONE add foo, [], [ignore], [ignore])
+COMMIT(testbranch)
+
+AT_CLEANUP
--- testsuite.at
+++ testsuite.at
@@ -37,6 +37,10 @@
# Save the PWD so MONOTONE macro can refer back to it
_ROOT_DIR=`pwd -P`
+# Pick a random port, so running multiple testsuites concurrently on
+# the same machine has a hope of working.
+_PORT=`awk 'BEGIN {srand()} END {printf "%.0f\n", (rand() * 450 + 20050)}'< /dev/null`
+
AT_DATA(test_keys, [@<:@pubkey address@hidden@:>@
MIGdMA0GCSqGSIb3DQEBAQUAA4GLADCBhwKBgQCfN/cAMabgb6T7m8ksGnpQ7LO6hOdnc/7V
yivrRGtmpwSItljht1bmgLQF37KiSPoMEDUb1stfKxaMsYiy8iTyoQ+M2EVFP37n2rtnNZ0H
@@ -336,13 +340,13 @@
# note that NETSYNC_SERVE_START is _not_ a special case of this macro.
m4_define([NETSYNC_SERVE_N_START], [
NETSYNC_KILLHARD
-MONOTONE --db=test$1.db --rcfile=netsync.lua serve localhost:5555 $2 &
+MONOTONE --db=test$1.db --rcfile=netsync.lua serve localhost:$_PORT $2 &
sleep 4
])
# run as NETSYNC_SERVE_START(collection name)
m4_define([NETSYNC_SERVE_START], [
NETSYNC_KILLHARD
-MONOTONE --rcfile=netsync.lua serve localhost:5555 $1 &
+MONOTONE --rcfile=netsync.lua serve localhost:$_PORT $1 &
sleep 4
])
# run as NETSYNC_SERVE_STOP
@@ -354,7 +358,7 @@
# run as NETSYNC_CLIENT_N_RUN(2|3, push|pull|sync, collection name[, expected result])
# first argument chooses whether to use the 2nd or 3rd database
m4_define([NETSYNC_CLIENT_N_RUN], [
-AT_CHECK(MONOTONE --db=test$1.db --rcfile=netsync.lua $2 localhost:5555 $3, [$4], [ignore], [ignore])
+AT_CHECK(MONOTONE --db=test$1.db --rcfile=netsync.lua $2 localhost:$_PORT $3, [$4], [ignore], [ignore])
])
# run as NETSYNC_CLIENT_RUN(push|pull|sync, collection name[, expected result])
m4_define([NETSYNC_CLIENT_RUN], [
@@ -551,3 +555,7 @@
m4_include(tests/t_netsync_largish_file.at)
m4_include(tests/t_update_off_branch.at)
m4_include(tests/t_setup_checkout_modify_new_dir.at)
+m4_include(tests/t_rename_dir_add_dir_with_old_name.at)
+m4_include(tests/t_rcs_import.at)
+m4_include(tests/t_cvsimport2.at)
+m4_include(tests/t_lf_crlf.at)