Merge
added missing gc, unit tests ok (almost)
This commit is contained in:
@@ -49,6 +49,10 @@ CmdMerge::CmdMerge ()
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
int CmdMerge::execute (std::string& output)
|
||||
{
|
||||
// invoke gc before merging in order to update data files
|
||||
context.tdb.gc ();
|
||||
context.tdb2.gc ();
|
||||
|
||||
std::vector <std::string> words = context.a3.extract_words ();
|
||||
std::string file;
|
||||
if (words.size ())
|
||||
@@ -92,6 +96,7 @@ int CmdMerge::execute (std::string& output)
|
||||
if ( ((sAutopush == "ask") && (confirm ("Would you like to push the merged changes to \'" + uri._data + "\'?")) )
|
||||
|| (bAutopush) )
|
||||
{
|
||||
// TODO derive autopush uri from merge.default.uri? otherwise: change prompt above
|
||||
// context.task.set ("description", uri._data);
|
||||
|
||||
std::string out;
|
||||
|
||||
@@ -159,7 +159,7 @@ my $report_r = qx{../src/task rc:remote.rc list};
|
||||
like ($report_l, qr/left_added/, "local-merge: left_added is present");
|
||||
like ($report_l, qr/right_added/, "local-merge: right_added is present");
|
||||
like ($report_l, qr/H.*left_modified/, "local-merge: left_modified ok");
|
||||
like ($report_l, qr/\*.*left_newer.*stay/, "local-merge: left_newer ok");
|
||||
like ($report_l, qr/\*.*left_newer.*stay/, "local-merge: left_newer ok, undo-completed");
|
||||
like ($report_l, qr/realProject.*right_newer.*gym/, "local-merge: right_newer ok");
|
||||
|
||||
$report_l = qx{../src/task rc:local.rc export};
|
||||
|
||||
Reference in New Issue
Block a user