You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by iv...@apache.org on 2015/03/04 16:56:21 UTC
svn commit: r1664059 [4/11] - in /subversion/branches/reuse-ra-session: ./
build/generator/ doc/ subversion/bindings/javahl/native/
subversion/bindings/swig/ subversion/bindings/swig/include/
subversion/bindings/swig/python/libsvn_swig_py/ subversion/b...
Modified: subversion/branches/reuse-ra-session/subversion/svn/props.c
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/svn/props.c?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/svn/props.c (original)
+++ subversion/branches/reuse-ra-session/subversion/svn/props.c Wed Mar 4 15:56:18 2015
@@ -112,59 +112,6 @@ svn_cl__check_boolean_prop_val(const cha
}
}
-
-/* Context for sorting property names */
-struct simprop_context_t
-{
- svn_string_t name; /* The name of the property we're comparing with */
- svn_membuf_t buffer; /* Buffer for similarity testing */
-};
-
-struct simprop_t
-{
- const char *propname; /* The original svn: property name */
- svn_string_t name; /* The property name without the svn: prefix */
- unsigned int score; /* The similarity score */
- apr_size_t diff; /* Number of chars different from context.name */
- struct simprop_context_t *context; /* Sorting context for qsort() */
-};
-
-/* Similarity test between two property names */
-static APR_INLINE unsigned int
-simprop_key_diff(const svn_string_t *key, const svn_string_t *ctx,
- svn_membuf_t *buffer, apr_size_t *diff)
-{
- apr_size_t lcs;
- const unsigned int score = svn_string__similarity(key, ctx, buffer, &lcs);
- if (key->len > ctx->len)
- *diff = key->len - lcs;
- else
- *diff = ctx->len - lcs;
- return score;
-}
-
-/* Key comparator for qsort for simprop_t */
-static int
-simprop_compare(const void *pkeya, const void *pkeyb)
-{
- struct simprop_t *const keya = *(struct simprop_t *const *)pkeya;
- struct simprop_t *const keyb = *(struct simprop_t *const *)pkeyb;
- struct simprop_context_t *const context = keya->context;
-
- if (keya->score == -1)
- keya->score = simprop_key_diff(&keya->name, &context->name,
- &context->buffer, &keya->diff);
- if (keyb->score == -1)
- keyb->score = simprop_key_diff(&keyb->name, &context->name,
- &context->buffer, &keyb->diff);
-
- return (keya->score < keyb->score ? 1
- : (keya->score > keyb->score ? -1
- : (keya->diff > keyb->diff ? 1
- : (keya->diff < keyb->diff ? -1 : 0))));
-}
-
-
static const char*
force_prop_option_message(svn_cl__prop_use_t prop_use, const char *prop_name,
apr_pool_t *scratch_pool)
@@ -174,18 +121,18 @@ force_prop_option_message(svn_cl__prop_u
case svn_cl__prop_use_set:
return apr_psprintf(
scratch_pool,
- _("(To set the '%s' property, re-run with '--force'.)"),
+ _("Use '--force' to set the '%s' property."),
prop_name);
case svn_cl__prop_use_edit:
return apr_psprintf(
scratch_pool,
- _("(To edit the '%s' property, re-run with '--force'.)"),
+ _("Use '--force' to edit the '%s' property."),
prop_name);
case svn_cl__prop_use_use:
default:
return apr_psprintf(
scratch_pool,
- _("(To use the '%s' property, re-run with '--force'.)"),
+ _("Use '--force' to use the '%s' property'."),
prop_name);
}
}
@@ -199,21 +146,18 @@ wrong_prop_error_message(svn_cl__prop_us
case svn_cl__prop_use_set:
return apr_psprintf(
scratch_pool,
- _("'%s' is not a valid %s property name;"
- " re-run with '--force' to set it"),
+ _("'%s' is not a valid %s property name; use '--force' to set it"),
prop_name, SVN_PROP_PREFIX);
case svn_cl__prop_use_edit:
return apr_psprintf(
scratch_pool,
- _("'%s' is not a valid %s property name;"
- " re-run with '--force' to edit it"),
+ _("'%s' is not a valid %s property name; use '--force' to edit it"),
prop_name, SVN_PROP_PREFIX);
case svn_cl__prop_use_use:
default:
return apr_psprintf(
scratch_pool,
- _("'%s' is not a valid %s property name;"
- " re-run with '--force' to use it"),
+ _("'%s' is not a valid %s property name; use '--force' to use it"),
prop_name, SVN_PROP_PREFIX);
}
}
@@ -239,33 +183,34 @@ svn_cl__check_svn_prop_name(const char *
const char *const *const proplist = (revprop ? revprops : nodeprops);
const apr_size_t numprops = (revprop ? revprops_len : nodeprops_len);
- struct simprop_t **propkeys;
- struct simprop_t *propbuf;
+ svn_cl__simcheck_t **propkeys;
+ svn_cl__simcheck_t *propbuf;
apr_size_t i;
- struct simprop_context_t context;
+ svn_string_t propstring;
svn_string_t prefix;
+ svn_membuf_t buffer;
- context.name.data = propname;
- context.name.len = strlen(propname);
+ propstring.data = propname;
+ propstring.len = strlen(propname);
prefix.data = SVN_PROP_PREFIX;
prefix.len = strlen(SVN_PROP_PREFIX);
- svn_membuf__create(&context.buffer, 0, scratch_pool);
+ svn_membuf__create(&buffer, 0, scratch_pool);
/* First, check if the name is even close to being in the svn: namespace.
It must contain a colon in the right place, and we only allow
one-char typos or a single transposition. */
- if (context.name.len < prefix.len
- || context.name.data[prefix.len - 1] != prefix.data[prefix.len - 1])
+ if (propstring.len < prefix.len
+ || propstring.data[prefix.len - 1] != prefix.data[prefix.len - 1])
return SVN_NO_ERROR; /* Wrong prefix, ignore */
else
{
apr_size_t lcs;
- const apr_size_t name_len = context.name.len;
- context.name.len = prefix.len; /* Only check up to the prefix length */
- svn_string__similarity(&context.name, &prefix, &context.buffer, &lcs);
- context.name.len = name_len; /* Restore the original propname length */
+ const apr_size_t name_len = propstring.len;
+ propstring.len = prefix.len; /* Only check up to the prefix length */
+ svn_string__similarity(&propstring, &prefix, &buffer, &lcs);
+ propstring.len = name_len; /* Restore the original propname length */
if (lcs < prefix.len - 1)
return SVN_NO_ERROR; /* Wrong prefix, ignore */
@@ -276,11 +221,11 @@ svn_cl__check_svn_prop_name(const char *
for (i = 0; i < numprops; ++i)
{
if (0 == strcmp(proplist[i] + prefix.len, propname + prefix.len))
- return svn_error_createf(
+ return svn_error_quick_wrap(svn_error_createf(
SVN_ERR_CLIENT_PROPERTY_NAME, NULL,
_("'%s' is not a valid %s property name;"
- " did you mean '%s'?\n%s"),
- propname, SVN_PROP_PREFIX, proplist[i],
+ " did you mean '%s'?"),
+ propname, SVN_PROP_PREFIX, proplist[i]),
force_prop_option_message(prop_use, propname, scratch_pool));
}
return SVN_NO_ERROR;
@@ -292,65 +237,59 @@ svn_cl__check_svn_prop_name(const char *
we already know that it's the same and looking at it would only
skew the results. */
propkeys = apr_palloc(scratch_pool,
- numprops * sizeof(struct simprop_t*));
+ numprops * sizeof(svn_cl__simcheck_t*));
propbuf = apr_palloc(scratch_pool,
- numprops * sizeof(struct simprop_t));
- context.name.data += prefix.len;
- context.name.len -= prefix.len;
+ numprops * sizeof(svn_cl__simcheck_t));
+ propstring.data += prefix.len;
+ propstring.len -= prefix.len;
for (i = 0; i < numprops; ++i)
{
propkeys[i] = &propbuf[i];
- propbuf[i].propname = proplist[i];
- propbuf[i].name.data = proplist[i] + prefix.len;
- propbuf[i].name.len = strlen(propbuf[i].name.data);
- propbuf[i].score = (unsigned int)-1;
- propbuf[i].context = &context;
+ propbuf[i].token.data = proplist[i] + prefix.len;
+ propbuf[i].token.len = strlen(propbuf[i].token.data);
+ propbuf[i].data = proplist[i];
}
- qsort(propkeys, numprops, sizeof(*propkeys), simprop_compare);
-
- if (0 == propkeys[0]->diff)
- return SVN_NO_ERROR; /* We found an exact match. */
-
- /* See if we can suggest a sane alternative spelling */
- for (i = 0; i < numprops; ++i)
- if (propkeys[i]->score < 666) /* 2/3 similarity required */
- break;
-
- switch (i)
+ switch (svn_cl__similarity_check(
+ propstring.data, propkeys, numprops, scratch_pool))
{
case 0:
+ return SVN_NO_ERROR; /* We found an exact match. */
+
+ case 1:
/* The best alternative isn't good enough */
return svn_error_create(
SVN_ERR_CLIENT_PROPERTY_NAME, NULL,
wrong_prop_error_message(prop_use, propname, scratch_pool));
- case 1:
+ case 2:
/* There is only one good candidate */
- return svn_error_createf(
+ return svn_error_quick_wrap(svn_error_createf(
SVN_ERR_CLIENT_PROPERTY_NAME, NULL,
- _("'%s' is not a valid %s property name; did you mean '%s'?\n%s"),
- propname, SVN_PROP_PREFIX, propkeys[0]->propname,
+ _("'%s' is not a valid %s property name; did you mean '%s'?"),
+ propname, SVN_PROP_PREFIX,
+ (const char *)propkeys[0]->data),
force_prop_option_message(prop_use, propname, scratch_pool));
- case 2:
+ case 3:
/* Suggest a list of the most likely candidates */
- return svn_error_createf(
+ return svn_error_quick_wrap(svn_error_createf(
SVN_ERR_CLIENT_PROPERTY_NAME, NULL,
- _("'%s' is not a valid %s property name\n"
- "Did you mean '%s' or '%s'?\n%s"),
+ _("'%s' is not a valid %s property name; "
+ "did you mean '%s' or '%s'?"),
propname, SVN_PROP_PREFIX,
- propkeys[0]->propname, propkeys[1]->propname,
+ (const char *)propkeys[0]->data, (const char *)propkeys[1]->data),
force_prop_option_message(prop_use, propname, scratch_pool));
default:
/* Never suggest more than three candidates */
- return svn_error_createf(
+ return svn_error_quick_wrap(svn_error_createf(
SVN_ERR_CLIENT_PROPERTY_NAME, NULL,
- _("'%s' is not a valid %s property name\n"
- "Did you mean '%s', '%s' or '%s'?\n%s"),
+ _("'%s' is not a valid %s property name; "
+ "did you mean '%s', '%s' or '%s'?"),
propname, SVN_PROP_PREFIX,
- propkeys[0]->propname, propkeys[1]->propname, propkeys[2]->propname,
+ (const char *)propkeys[0]->data,
+ (const char *)propkeys[1]->data, (const char *)propkeys[2]->data),
force_prop_option_message(prop_use, propname, scratch_pool));
}
}
Modified: subversion/branches/reuse-ra-session/subversion/svn/svn.c
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/svn/svn.c?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/svn/svn.c (original)
+++ subversion/branches/reuse-ra-session/subversion/svn/svn.c Wed Mar 4 15:56:18 2015
@@ -110,7 +110,7 @@ typedef enum svn_cl__longopt_t {
opt_remove,
opt_revprop,
opt_stop_on_copy,
- opt_strict,
+ opt_strict, /* ### DEPRECATED */
opt_targets,
opt_depth,
opt_set_depth,
@@ -146,6 +146,7 @@ typedef enum svn_cl__longopt_t {
opt_no_newline,
opt_show_passwords,
opt_pin_externals,
+ opt_show_item,
} svn_cl__longopt_t;
@@ -232,7 +233,7 @@ const apr_getopt_option_t svn_cl__option
" "
"'empty', 'files', 'immediates', or 'infinity')")},
{"xml", opt_xml, 0, N_("output in XML")},
- {"strict", opt_strict, 0, N_("use strict semantics")},
+ {"strict", opt_strict, 0, N_("DEPRECATED")},
{"stop-on-copy", opt_stop_on_copy, 0,
N_("do not cross copies while traversing history")},
{"no-ignore", opt_no_ignore, 0,
@@ -423,6 +424,8 @@ const apr_getopt_option_t svn_cl__option
N_("pin externals with no explicit revision to their\n"
" "
"current revision (recommended when tagging)")},
+ {"show-item", opt_show_item, 1,
+ N_("print only the item identified by ARG")},
/* Long-opt Aliases
*
@@ -736,9 +739,24 @@ const svn_opt_subcommand_desc2_t svn_cl_
"\n"
" Print information about each TARGET (default: '.').\n"
" TARGET may be either a working-copy path or URL. If specified, REV\n"
- " determines in which revision the target is first looked up.\n"),
+ " determines in which revision the target is first looked up.\n"
+ "\n"
+ " With --show-item, print only the value of one item of information\n"
+ " about TARGET. One of the following items can be selected:\n"
+ " kind the kind of TARGET\n"
+ " url the URL of TARGET in the repository\n"
+ " relative-url the repository-relative URL\n"
+ " repos-root-url the repository root URL\n"
+ " repos-uuid the repository UUID\n"
+ " revision the revision of TARGET (defaults to BASE\n"
+ " for working copy paths and HEAD for URLs)\n"
+ " last-changed-revision the most recent revision in which TARGET\n"
+ " was changed\n"
+ " last-changed-date the date of the last-changed revision\n"
+ " last-changed-author the author of the last-changed revision\n"
+ " wc-root the root of TARGET's working copy"),
{'r', 'R', opt_depth, opt_targets, opt_incremental, opt_xml,
- opt_changelist, opt_include_externals}
+ opt_changelist, opt_include_externals, opt_show_item, opt_no_newline}
},
{ "list", svn_cl__list, {"ls"}, N_
@@ -1355,14 +1373,14 @@ const svn_opt_subcommand_desc2_t svn_cl_
"\n"
" By default, an extra newline is printed after the property value so that\n"
" the output looks pretty. With a single TARGET, depth 'empty' and without\n"
- " --show-inherited-props, you can use the --strict option to disable this\n"
+ " --show-inherited-props, you can use the --no-newline option to disable this\n"
" (useful when redirecting a binary property value to a file, for example).\n"
"\n"
" See 'svn help propset' for descriptions of the svn:* special properties.\n"),
- {'v', 'R', opt_depth, 'r', opt_revprop, opt_strict, opt_xml,
+ {'v', 'R', opt_depth, 'r', opt_revprop, opt_strict, opt_no_newline, opt_xml,
opt_changelist, opt_show_inherited_props },
{{'v', N_("print path, name and value on separate lines")},
- {opt_strict, N_("don't print an extra newline")}} },
+ {opt_strict, N_("(deprecated; use --no-newline)")}} },
{ "proplist", svn_cl__proplist, {"plist", "pl"}, N_
("List all properties on files, dirs, or revisions.\n"
@@ -2154,9 +2172,6 @@ sub_main(int *exit_code, int argc, const
case opt_stop_on_copy:
opt_state.stop_on_copy = TRUE;
break;
- case opt_strict:
- opt_state.strict = TRUE;
- break;
case opt_no_ignore:
opt_state.no_ignore = TRUE;
break;
@@ -2398,6 +2413,7 @@ sub_main(int *exit_code, int argc, const
opt_state.remove_ignored = TRUE;
break;
case opt_no_newline:
+ case opt_strict: /* ### DEPRECATED */
opt_state.no_newline = TRUE;
break;
case opt_show_passwords:
@@ -2406,6 +2422,10 @@ sub_main(int *exit_code, int argc, const
case opt_pin_externals:
opt_state.pin_externals = TRUE;
break;
+ case opt_show_item:
+ SVN_ERR(svn_utf_cstring_to_utf8(&utf8_opt_arg, opt_arg, pool));
+ opt_state.show_item = utf8_opt_arg;
+ break;
default:
/* Hmmm. Perhaps this would be a good place to squirrel away
opts that commands like svn diff might need. Hmmm indeed. */
@@ -3038,10 +3058,9 @@ sub_main(int *exit_code, int argc, const
if (err->apr_err == SVN_ERR_CL_INSUFFICIENT_ARGS
|| err->apr_err == SVN_ERR_CL_ARG_PARSING_ERROR)
{
- err = svn_error_quick_wrap(
- err, apr_psprintf(pool,
- _("Try 'svn help %s' for more information"),
- subcommand->name));
+ err = svn_error_quick_wrapf(
+ err, _("Try 'svn help %s' for more information"),
+ subcommand->name);
}
if (err->apr_err == SVN_ERR_WC_UPGRADE_REQUIRED)
{
Modified: subversion/branches/reuse-ra-session/subversion/svnbench/svnbench.c
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/svnbench/svnbench.c?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/svnbench/svnbench.c (original)
+++ subversion/branches/reuse-ra-session/subversion/svnbench/svnbench.c Wed Mar 4 15:56:18 2015
@@ -958,10 +958,9 @@ sub_main(int *exit_code, int argc, const
if (err->apr_err == SVN_ERR_CL_INSUFFICIENT_ARGS
|| err->apr_err == SVN_ERR_CL_ARG_PARSING_ERROR)
{
- err = svn_error_quick_wrap(
- err, apr_psprintf(pool,
- _("Try 'svnbench help %s' for more information"),
- subcommand->name));
+ err = svn_error_quick_wrapf(
+ err, _("Try 'svnbench help %s' for more information"),
+ subcommand->name);
}
if (err->apr_err == SVN_ERR_WC_UPGRADE_REQUIRED)
{
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/authz_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/authz_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/authz_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/authz_tests.py Wed Mar 4 15:56:18 2015
@@ -83,7 +83,7 @@ def authz_open_root(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
None,
- None,
+ [],
mu_path)
#----------------------------------------------------------------------
@@ -119,9 +119,7 @@ def authz_open_directory(sbox):
# Commit the working copy.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- None,
- None,
- wc_dir)
+ None)
@Skip(svntest.main.is_ra_type_file)
@SkipDumpLoadCrossCheck()
@@ -392,9 +390,9 @@ def authz_checkout_test(sbox):
expected_wc = svntest.main.greek_state
svntest.actions.run_and_verify_checkout(sbox.repo_url,
- local_dir,
- expected_output,
- expected_wc)
+ local_dir,
+ expected_output,
+ expected_wc)
@Skip(svntest.main.is_ra_type_file)
def authz_checkout_and_update_test(sbox):
@@ -456,9 +454,7 @@ def authz_checkout_and_update_test(sbox)
expected_output,
expected_wc,
expected_status,
- None,
- None, None,
- None, None, 1)
+ [], True)
@Skip(svntest.main.is_ra_type_file)
def authz_partial_export_test(sbox):
@@ -770,7 +766,7 @@ def authz_locking(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
[],
- None,
+ [],
mu_path)
# Lock two paths one of which fails. First add read access to '/' so
@@ -1135,7 +1131,7 @@ def case_sensitive_authz(sbox):
})
# error messages
- expected_error_for_commit = "Commit failed"
+ expected_error_for_commit = ".*Commit failed.*"
if sbox.repo_url.startswith("http"):
expected_error_for_cat = ".*[Ff]orbidden.*"
@@ -1204,7 +1200,7 @@ def case_sensitive_authz(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
None,
- None,
+ [],
mu_path)
@Skip(svntest.main.is_ra_type_file)
@@ -1233,7 +1229,7 @@ def authz_tree_conflict(sbox):
expected_output,
None,
expected_status,
- None, None, None, None, None, 0,
+ [], False,
'-r', '1', wc_dir)
@Issue(3900)
@@ -1432,9 +1428,7 @@ def remove_subdir_with_authz_and_tc(sbox
expected_output,
None,
expected_status,
- None,
- None, None,
- None, None, False,
+ [], False,
wc_dir, '-r', '1')
# Perform some edit operation to introduce a tree conflict
@@ -1449,11 +1443,7 @@ def remove_subdir_with_authz_and_tc(sbox
svntest.actions.run_and_verify_update(wc_dir,
expected_output,
None,
- None,
- None,
- None, None,
- None, None, False,
- wc_dir)
+ None)
@SkipUnless(svntest.main.is_ra_type_svn)
def authz_svnserve_groups(sbox):
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/basic_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/basic_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/basic_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/basic_tests.py Wed Mar 4 15:56:18 2015
@@ -140,9 +140,7 @@ def basic_commit(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -176,7 +174,7 @@ def basic_update(sbox):
# Commit.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
# Create expected output tree for an update of the wc_backup.
expected_output = wc.State(wc_backup, {
@@ -406,8 +404,7 @@ def basic_commit_corruption(sbox):
# This commit should fail due to text base corruption.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
None, # expected_status,
- "svn: E200014: Checksum",
- wc_dir)
+ "svn: E200014: Checksum")
# Restore the uncorrupted text base.
os.chmod(tb_dir_path, 0777)
@@ -419,7 +416,7 @@ def basic_commit_corruption(sbox):
# This commit should succeed.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
#----------------------------------------------------------------------
def basic_update_corruption(sbox):
@@ -463,7 +460,7 @@ def basic_update_corruption(sbox):
# This commit should succeed.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
# Create expected output tree for an update of the other_wc.
expected_output = wc.State(other_wc, {
@@ -499,7 +496,7 @@ def basic_update_corruption(sbox):
fail_output,
expected_disk,
fail_status,
- "svn: E155017: Checksum", other_wc)
+ "svn: E155017: Checksum")
# Restore the uncorrupted text base.
os.chmod(tb_dir_path, 0777)
@@ -556,7 +553,7 @@ def basic_merging_update(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir)
# Make a backup copy of the working copy
@@ -582,7 +579,7 @@ def basic_merging_update(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir)
# Make local mods to wc_backup by recreating mu and rho
@@ -663,7 +660,7 @@ def basic_conflict(sbox):
# Commit.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
# Create expected output tree for an update of the wc_backup.
expected_output = wc.State(wc_backup, {
@@ -707,9 +704,7 @@ def basic_conflict(sbox):
expected_output,
expected_disk,
expected_status,
- None,
- svntest.tree.detect_conflict_files,
- extra_files)
+ extra_files=extra_files)
# verify that the extra_files list is now empty.
if len(extra_files) != 0:
@@ -977,7 +972,7 @@ def basic_switch(sbox):
expected_output,
expected_disk,
expected_status,
- None, None, None, None, None,
+ [],
False, '--ignore-ancestry')
### Switch the directory `A/D/H' to `A/D/G'.
@@ -1037,7 +1032,7 @@ def basic_switch(sbox):
expected_output,
expected_disk,
expected_status,
- None, None, None, None, None,
+ [],
False, '--ignore-ancestry')
#----------------------------------------------------------------------
@@ -1290,8 +1285,7 @@ def basic_checkout_deleted(sbox):
'A/D/gamma')
svntest.actions.run_and_verify_commit(wc_dir,
- expected_output, expected_status,
- None, wc_dir)
+ expected_output, expected_status)
# Now try to checkout revision 1 of A/D.
url = sbox.repo_url + '/A/D'
@@ -1333,8 +1327,7 @@ def basic_node_kind_change(sbox):
expected_status = svntest.actions.get_virginal_state(wc_dir, 1)
expected_status.tweak('A/D/gamma', status=' ', wc_rev='2')
svntest.actions.run_and_verify_commit(wc_dir,
- expected_output, expected_status,
- None, wc_dir)
+ expected_output, expected_status)
# Try and fail to create a directory (file deleted)
svntest.actions.run_and_verify_svn(None, svntest.verify.AnyOutput,
@@ -1412,8 +1405,7 @@ def basic_import(sbox):
expected_output,
expected_disk,
expected_status,
- None, None, None,
- None, None, 1)
+ [], True)
#----------------------------------------------------------------------
@@ -1679,9 +1671,7 @@ def basic_add_parents(sbox):
# Commit and verify
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
svntest.actions.run_and_verify_svn(None, [],
'rm', X_path, '--keep-local')
@@ -1850,9 +1840,7 @@ def info_nonhead(sbox):
expected_status.remove("iota")
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
# Get info for old iota at r1.
expected_infos = [
{ 'URL' : '.*' },
@@ -1881,8 +1869,7 @@ def ls_nonhead(sbox):
expected_status.remove('A/D/G', 'A/D/G/rho', 'A/D/G/pi', 'A/D/G/tau',)
svntest.actions.run_and_verify_commit(wc_dir,
- expected_output, expected_status,
- None, wc_dir)
+ expected_output, expected_status)
# Check that we can list a file in A/D/G at revision 1.
rho_url = sbox.repo_url + "/A/D/G/rho"
@@ -1949,9 +1936,7 @@ def delete_keep_local(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
# Update working copy to check disk state still greek tree
expected_disk = svntest.main.greek_state.copy()
@@ -2206,7 +2191,7 @@ def automatic_conflict_resolution(sbox):
# Commit.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
# Create expected output tree for an update of the wc_backup.
expected_output = wc.State(wc_backup, {
@@ -2285,21 +2270,7 @@ def automatic_conflict_resolution(sbox):
expected_output,
expected_disk,
expected_status,
- None,
- svntest.tree.detect_conflict_files,
- extra_files)
-
- # verify that the extra_files list is now empty.
- if len(extra_files) != 0:
- # Because we want to be a well-behaved test, we silently raise if
- # the test fails. However, these two print statements would
- # probably reveal the cause for the failure, if they were
- # uncommented:
- #
- # logger.warn("Not all extra reject files have been accounted for:")
- # logger.warn(extra_files)
- ### we should raise a less generic error here. which?
- raise svntest.Failure
+ extra_files=extra_files)
# So now lambda, mu and rho are all in a "conflicted" state. Run 'svn
# resolve' with the respective "--accept[mine|orig|repo]" flag.
@@ -2387,9 +2358,7 @@ def automatic_conflict_resolution(sbox):
expected_output,
expected_disk,
expected_status,
- None,
- svntest.tree.detect_conflict_files,
- extra_files)
+ extra_files=extra_files)
def info_nonexisting_file(sbox):
"get info on a file not in the repo"
@@ -2687,9 +2656,7 @@ def delete_and_add_same_file(sbox):
# not found".
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
def delete_child_parent_update(sbox):
"rm child, commit, rm parent"
@@ -2708,9 +2675,7 @@ def delete_child_parent_update(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
svntest.main.run_svn(wc_dir, 'rm', sbox.ospath('A/B/E'))
expected_status.tweak('A/B/E', 'A/B/E/beta', status='D ')
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/blame_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/blame_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/blame_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/blame_tests.py Wed Mar 4 15:56:18 2015
@@ -213,7 +213,7 @@ def blame_in_xml(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# Retrieve last changed date from svn info
exit_code, output, error = svntest.actions.run_and_verify_svn(
@@ -284,7 +284,7 @@ def blame_on_unknown_revision(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
exit_code, output, error = svntest.actions.run_and_verify_svn(
None, [],
@@ -355,13 +355,13 @@ def blame_eol_styles(sbox):
for i in range(1,3):
svntest.main.file_append(file_path, "Extra line %d" % (i) + "\n")
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
svntest.main.run_svn(None, 'propset', 'svn:eol-style', eol,
file_path)
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
exit_code, output, error = svntest.actions.run_and_verify_svn(
None, [],
@@ -389,7 +389,7 @@ def blame_ignore_whitespace(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# commit only whitespace changes
svntest.main.file_write(file_path,
@@ -400,7 +400,7 @@ def blame_ignore_whitespace(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# match the blame output, as defined in the blame code:
# "%6ld %10s %s %s%s", rev, author ? author : " -",
@@ -425,7 +425,7 @@ def blame_ignore_whitespace(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
expected_output = [
" 2 jrandom A a \n",
@@ -454,7 +454,7 @@ def blame_ignore_eolstyle(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# commit only eol changes
svntest.main.file_write(file_path,
@@ -465,7 +465,7 @@ def blame_ignore_eolstyle(sbox):
'iota' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
expected_output = [
" 2 jrandom Aa\n",
@@ -652,7 +652,7 @@ def blame_output_after_merge(sbox):
'trunk/A/mu' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# r4: create branches/br from trunk
branches_br_url = sbox.repo_url + "/branches/br"
@@ -678,7 +678,7 @@ def blame_output_after_merge(sbox):
'branches/br/A/mu' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# r6: Insert a single line in branches/A/mu
svntest.main.file_write(branch_mu_path,
@@ -694,7 +694,7 @@ def blame_output_after_merge(sbox):
'branches/br/A/mu' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# r7: merge branches/br back to trunk
trunk_path = os.path.join(wc_dir, "trunk")
@@ -706,7 +706,7 @@ def blame_output_after_merge(sbox):
'trunk/A/mu' : Item(verb='Sending'),
})
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- None, None, wc_dir)
+ None)
# Now test blame, first without the -g option
expected_output = [ " 3 jrandom New version of file 'mu'.\n",
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/changelist_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/changelist_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/changelist_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/changelist_tests.py Wed Mar 4 15:56:18 2015
@@ -442,7 +442,7 @@ def commit_one_changelist(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir,
"--changelist",
"a")
@@ -483,7 +483,7 @@ def commit_multiple_changelists(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir,
"--changelist", "a",
"--changelist", "i")
@@ -814,8 +814,7 @@ def update_with_changelists(sbox):
expected_output,
expected_disk,
expected_status,
- None, None, None,
- None, None, 1,
+ [], True,
"-r", "1",
"--changelist", "a",
"--changelist", "i",
@@ -856,8 +855,7 @@ def update_with_changelists(sbox):
expected_output,
expected_disk,
expected_status,
- None, None, None,
- None, None, 1,
+ [], True,
"-r", "1",
"--changelist", "a",
"--changelist", "i",
@@ -907,7 +905,7 @@ def tree_conflicts_and_changelists_on_co
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir,
"--changelist",
"list")
@@ -980,7 +978,7 @@ def tree_conflicts_and_changelists_on_co
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir,
"--changelist",
"list")
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/checkout_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/checkout_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/checkout_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/checkout_tests.py Wed Mar 4 15:56:18 2015
@@ -206,8 +206,8 @@ def checkout_with_obstructions(sbox):
'A/B/lambda', 'A/D', 'A/D/G', 'A/D/G/rho', 'A/D/G/pi', 'A/D/G/tau',
'A/D/H', 'A/D/H/psi', 'A/D/H/omega', 'A/D/H/chi', 'A/D/gamma', 'A/C')
- actions.run_and_verify_checkout2(False, url, wc_dir, expected_output,
- expected_disk, None, None, None, None)
+ actions.run_and_verify_checkout(url, wc_dir, expected_output,
+ expected_disk)
# svn status
expected_status = actions.get_virginal_state(wc_dir, 1)
@@ -243,7 +243,7 @@ def checkout_with_obstructions(sbox):
expected_status = actions.get_virginal_state(wc_dir, 1)
actions.run_and_verify_update(wc_dir, expected_output, expected_disk,
- expected_status, None, None, None, None, None, False, wc_dir)
+ expected_status,)
@@ -291,7 +291,7 @@ def forced_checkout_of_file_with_dir_obs
expected_disk.tweak('iota', contents=None)
actions.run_and_verify_checkout(url, wc_dir_other, expected_output,
- expected_disk, None, None, None, None, '--force')
+ expected_disk, [], '--force')
#----------------------------------------------------------------------
@@ -356,7 +356,7 @@ def forced_checkout_of_dir_with_file_obs
expected_disk.tweak('A', contents='The file A\n')
actions.run_and_verify_checkout(url, wc_dir_other, expected_output,
- expected_disk, None, None, None, None, '--force')
+ expected_disk, [], '--force')
# Now see to it that we can recover from the obstructions.
@@ -374,7 +374,7 @@ def forced_checkout_of_dir_with_file_obs
svntest.main.run_svn(None, 'revert', '-R', os.path.join(wc_dir_other, 'A'))
actions.run_and_verify_update(wc_dir_other, expected_output, expected_disk,
- expected_status, None, None, None, None, None, False, wc_dir_other)
+ expected_status)
#----------------------------------------------------------------------
@@ -390,8 +390,7 @@ def forced_checkout_with_faux_obstructio
svntest.actions.run_and_verify_checkout(sbox.repo_url,
sbox.wc_dir, expected_output,
- expected_wc, None, None, None,
- None, '--force')
+ expected_wc, [], '--force')
#----------------------------------------------------------------------
@@ -411,8 +410,7 @@ def forced_checkout_with_real_obstructio
svntest.actions.run_and_verify_checkout(sbox.repo_url,
sbox.wc_dir, expected_output,
- expected_wc, None, None, None,
- None, '--force')
+ expected_wc, [], '--force')
#----------------------------------------------------------------------
@@ -436,8 +434,7 @@ def forced_checkout_with_real_obstructio
svntest.actions.run_and_verify_checkout(sbox.repo_url,
sbox.wc_dir, expected_output,
- expected_wc, None, None, None,
- None, '--force')
+ expected_wc, [], '--force')
#----------------------------------------------------------------------
@@ -481,8 +478,7 @@ def forced_checkout_with_versioned_obstr
expected_wc = svntest.main.greek_state.copy()
svntest.actions.run_and_verify_checkout(repo_url, fresh_wc_dir,
expected_output, expected_wc,
- None, None, None, None,
- '--force')
+ [], '--force')
# Checkout the entire first repos into the other dir. This should
# fail because it's a different repository.
@@ -493,8 +489,7 @@ def forced_checkout_with_versioned_obstr
expected_wc = svntest.main.greek_state.copy()
svntest.actions.run_and_verify_checkout(repo_url, other_wc_dir,
expected_output, expected_wc,
- None, None, None, None,
- '--force')
+ [], '--force')
#ensure that other_wc_dir_A is not affected by this forced checkout.
svntest.actions.run_and_verify_svn(None,
@@ -573,8 +568,7 @@ def import_and_checkout(sbox):
svntest.actions.run_and_verify_checkout(other_repo_url, import_from_dir,
expected_output, expected_wc,
- None, None, None, None,
- '--force')
+ [], '--force')
#----------------------------------------------------------------------
# Issue #2529.
@@ -584,7 +578,8 @@ def checkout_broken_eol(sbox):
svntest.actions.load_repo(sbox, os.path.join(os.path.dirname(sys.argv[0]),
'update_tests_data',
- 'checkout_broken_eol.dump'))
+ 'checkout_broken_eol.dump'),
+ create_wc=False)
URL = sbox.repo_url
@@ -662,7 +657,7 @@ def checkout_peg_rev_date(sbox):
## Get svn:date.
exit_code, output, errput = svntest.main.run_svn(None, 'propget', 'svn:date',
'--revprop', '-r1',
- '--strict',
+ '--no-newline',
sbox.repo_url)
if exit_code or errput != [] or len(output) != 1:
raise svntest.Failure("svn:date propget failed")
@@ -807,7 +802,7 @@ def co_with_obstructing_local_adds(sbox)
# Commit.
svntest.actions.run_and_verify_commit(wc_dir, expected_output,
- expected_status, None, wc_dir)
+ expected_status)
# Create various paths scheduled for addition which will obstruct
# the adds coming from the repos.
@@ -895,9 +890,8 @@ def co_with_obstructing_local_adds(sbox)
# wc_backup before performing the checkout otherwise.
svntest.actions.run_and_verify_checkout(sbox.repo_url, wc_backup,
expected_output, expected_disk,
- svntest.tree.detect_conflict_files,
- extra_files, None, None,
- '--force')
+ [], '--force',
+ extra_files=extra_files)
svntest.actions.run_and_verify_status(wc_backup, expected_status)
@@ -1001,8 +995,7 @@ def co_with_obstructing_local_adds(sbox)
D_path,
expected_output,
expected_disk,
- None, None, None, None,
- '--force')
+ [], '--force')
expected_status.tweak('A/D/M', treeconflict='C', status='R ')
expected_status.tweak(
@@ -1041,8 +1034,7 @@ def co_with_obstructing_local_adds(sbox)
F_path,
expected_output,
expected_disk,
- None, None, None, None,
- '--force')
+ [], '--force')
expected_status.tweak('A/B/F/omicron', treeconflict='C', status='R ')
expected_status.add({
@@ -1122,8 +1114,7 @@ def checkout_wc_from_drive(sbox):
'iota' : Item(status='A '),
})
svntest.actions.run_and_verify_checkout(repo_url, wc_dir,
- expected_output, expected_wc,
- None, None, None, None)
+ expected_output, expected_wc)
wc2_dir = sbox.add_wc_path('2')
expected_output = wc.State(wc2_dir, {
@@ -1164,8 +1155,7 @@ def checkout_wc_from_drive(sbox):
})
svntest.actions.run_and_verify_checkout(repo_url + '/A', wc2_dir,
- expected_output, expected_wc,
- None, None, None, None)
+ expected_output, expected_wc)
wc3_dir = sbox.add_wc_path('3')
expected_output = wc.State(wc3_dir, {
@@ -1191,8 +1181,7 @@ def checkout_wc_from_drive(sbox):
})
svntest.actions.run_and_verify_checkout(repo_url + '/A/D', wc3_dir,
- expected_output, expected_wc,
- None, None, None, None)
+ expected_output, expected_wc)
finally:
os.chdir(was_cwd)
Modified: subversion/branches/reuse-ra-session/subversion/tests/cmdline/commit_tests.py
URL: http://svn.apache.org/viewvc/subversion/branches/reuse-ra-session/subversion/tests/cmdline/commit_tests.py?rev=1664059&r1=1664058&r2=1664059&view=diff
==============================================================================
--- subversion/branches/reuse-ra-session/subversion/tests/cmdline/commit_tests.py (original)
+++ subversion/branches/reuse-ra-session/subversion/tests/cmdline/commit_tests.py Wed Mar 4 15:56:18 2015
@@ -174,7 +174,7 @@ def commit_one_file(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
omega_path)
@@ -200,7 +200,7 @@ def commit_one_new_file(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
gloo_path)
@@ -229,7 +229,7 @@ def commit_one_new_binary_file(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
gloo_path)
@@ -283,7 +283,7 @@ def commit_multiple_targets(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
psi_path, AB_path, pi_path)
#----------------------------------------------------------------------
@@ -339,7 +339,7 @@ def commit_multiple_targets_2(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
psi_path, AB_path,
omega_path, pi_path)
@@ -375,7 +375,7 @@ def commit_inclusive_dir(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
D_path)
#----------------------------------------------------------------------
@@ -417,7 +417,7 @@ def commit_top_dir(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
wc_dir)
#----------------------------------------------------------------------
@@ -449,7 +449,7 @@ def commit_unversioned_thing(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
None,
None,
- "is not under version control",
+ ".*is not under version control.*",
os.path.join(wc_dir,'blorg'))
#----------------------------------------------------------------------
@@ -527,9 +527,7 @@ def nested_dir_replacements(sbox):
# Commit from the top of the working copy and verify output & status.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -560,8 +558,7 @@ def hudson_part_1(sbox):
# Commit the deletion of gamma and verify.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# Now gamma should be marked as `deleted' under the hood. When we
# update, we should no output, and a perfect, virginal status list
@@ -611,8 +608,7 @@ def hudson_part_1_variation_1(sbox):
# Commit the deletion of H and verify.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# Now H should be marked as `deleted' under the hood. When we
# update, we should no see output, and a perfect, virginal status
@@ -662,8 +658,7 @@ def hudson_part_1_variation_2(sbox):
# Commit the deletion of gamma and verify.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# Now gamma should be marked as `deleted' under the hood.
# Go ahead and re-add gamma, so that is *also* scheduled for addition.
@@ -688,8 +683,7 @@ def hudson_part_1_variation_2(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -722,8 +716,7 @@ def hudson_part_2(sbox):
# Commit the deletion of gamma and verify.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# Now gamma should be marked as `deleted' under the hood, at
# revision 2. Meanwhile, A/D is still lagging at revision 1.
@@ -735,8 +728,7 @@ def hudson_part_2(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
None,
None,
- "[Oo]ut.of.date",
- wc_dir)
+ ".*[Oo]ut of date.*")
#----------------------------------------------------------------------
@@ -787,8 +779,7 @@ def hudson_part_2_1(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# Now, assuming all three files in H are marked as 'deleted', an
# update of H should print absolutely nothing.
@@ -905,8 +896,7 @@ def merge_mixed_revisions(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# 2. svn up A/D/H
@@ -940,8 +930,7 @@ def merge_mixed_revisions(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# 4. echo "moo" >> A/D/H/chi; svn ci A/D/H/chi
@@ -955,8 +944,7 @@ def merge_mixed_revisions(sbox):
expected_status.tweak('iota', wc_rev=3)
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# 5. echo "moo" >> iota; svn ci iota
svntest.main.file_append(iota_path, "moomoo")
@@ -969,8 +957,7 @@ def merge_mixed_revisions(sbox):
expected_status.tweak('iota', wc_rev=5)
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
# At this point, here is what our tree should look like:
# _ 1 ( 5) working_copies/commit_tests-10
@@ -1011,8 +998,7 @@ def merge_mixed_revisions(sbox):
expected_status.tweak('A/D/H/chi', wc_rev=4)
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -1089,8 +1075,7 @@ def commit_uri_unsafe(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -1126,8 +1111,7 @@ def commit_deleted_edited(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None, wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -1234,9 +1218,7 @@ def commit_add_file_twice(sbox):
# Commit should succeed
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
# Update to state before commit
svntest.main.run_svn(None, 'up', '-r', '1', wc_dir)
@@ -1249,8 +1231,7 @@ def commit_add_file_twice(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
None,
None,
- "E160020: File.*already exists",
- wc_dir)
+ ".*E160020: File.*already exists.*")
#----------------------------------------------------------------------
@@ -1286,9 +1267,7 @@ def commit_from_long_dir(sbox):
svntest.actions.run_and_verify_commit(abs_wc_dir,
expected_output,
- None,
- None,
- abs_wc_dir)
+ None)
#----------------------------------------------------------------------
@@ -1309,8 +1288,7 @@ def commit_with_lock(sbox):
None,
None,
'svn: E155004: '
- 'Working copy \'.*\' locked',
- wc_dir)
+ 'Working copy \'.*\' locked')
# unlock directory
svntest.actions.run_and_verify_svn([], [],
@@ -1324,9 +1302,7 @@ def commit_with_lock(sbox):
expected_status.tweak('A/D/gamma', wc_rev=2)
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
#----------------------------------------------------------------------
@@ -1350,9 +1326,7 @@ def commit_current_dir(sbox):
})
svntest.actions.run_and_verify_commit('.',
expected_output,
- None,
- None,
- '.')
+ None)
os.chdir(was_cwd)
# I can't get the status check to work as part of run_and_verify_commit.
@@ -1622,7 +1596,7 @@ def commit_nonrecursive(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
'-N',
sbox.ospath(file1_path),
sbox.ospath(dir1_path),
@@ -1749,7 +1723,7 @@ def commit_nonrecursive(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
'-N', sbox.ospath(dirA_path))
#----------------------------------------------------------------------
@@ -1819,7 +1793,7 @@ def commit_out_of_date_deletions(sbox):
status=' ')
expected_status.remove('A/B/F', 'A/D/H/chi', 'A/B/E/beta', 'A/D/H/psi')
commit = svntest.actions.run_and_verify_commit
- commit(wc_dir, expected_output, expected_status, None, wc_dir)
+ commit(wc_dir, expected_output, expected_status, [], wc_dir)
# Edits in wc backup
I_path = os.path.join(wc_backup, 'A', 'I')
@@ -1840,7 +1814,7 @@ def commit_out_of_date_deletions(sbox):
# A commit of any one of these files or dirs should fail, preferably
# with an out-of-date error message.
- error_re = "(out of date|not found)"
+ error_re = ".*(out of date|not found).*"
commit(wc_backup, None, None, error_re, C_path)
commit(wc_backup, None, None, error_re, I_path)
commit(wc_backup, None, None, error_re, F_path)
@@ -1868,7 +1842,7 @@ def commit_with_bad_log_message(sbox):
# Commit and expect an error.
svntest.actions.run_and_verify_commit(wc_dir,
None, None,
- "contains a zero byte",
+ ".*contains a zero byte.*",
'-F', log_msg_path,
iota_path)
@@ -1890,9 +1864,10 @@ def commit_with_mixed_line_endings(sbox)
svntest.main.file_append(log_msg_path, "test\nthis\n\rcase\r\n--This line, and those below, will be ignored--\n")
# Commit and expect an error.
+ expected_stderr = ".*E135000: Error normalizing log message to internal format.*"
svntest.actions.run_and_verify_commit(wc_dir,
None, None,
- "Error normalizing log message to internal format",
+ expected_stderr,
'-F', log_msg_path,
iota_path)
@@ -1923,7 +1898,7 @@ def commit_with_mixed_line_endings_in_ig
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
iota_path)
def from_wc_top_with_bad_editor(sbox):
@@ -1991,8 +1966,7 @@ def mods_in_schedule_delete(sbox):
'A/C' : Item(verb='Deleting'),
})
svntest.actions.run_and_verify_commit(wc_dir,
- expected_output, expected_status,
- None, wc_dir)
+ expected_output, expected_status)
# Unversioned file still exists
actual_contents = open(foo_path).read()
@@ -2165,7 +2139,7 @@ def commit_same_folder_in_targets(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
'-N',
wc_dir,
iota_path)
@@ -2261,7 +2235,7 @@ def commit_with_revprop(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
'-m', 'msg',
'--with-revprop', 'bug=62',
omega_path, gloo_path)
@@ -2637,7 +2611,7 @@ def changelist_near_conflict(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
expected_status,
- None,
+ [],
"--changelist=" + changelist_name,
"-m", "msg", wc_dir)
@@ -2665,9 +2639,7 @@ def commit_out_of_date_file(sbox):
expected_status.tweak("A/D/G/pi", wc_rev=2, status=" ")
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- "-m", "log message", wc_dir)
+ expected_status)
svntest.main.file_append(backup_pi_path, "hello")
expected_err = ".*(pi.*out of date|Out of date.*pi).*"
@@ -2757,7 +2729,7 @@ def tree_conflicts_block_commit(sbox):
D = sbox.ospath('A/D')
G = sbox.ospath('A/D/G')
- error_re = "remains in conflict"
+ error_re = ".*remains in conflict.*"
commit_fails_at_path(wc_dir, wc_dir, error_re)
commit_fails_at_path(A, A, error_re)
commit_fails_at_path(D, D, error_re)
@@ -2831,9 +2803,7 @@ def commit_incomplete(sbox):
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
#----------------------------------------------------------------------
# Reported here:
@@ -2883,8 +2853,7 @@ def commit_danglers(sbox):
svntest.actions.run_and_verify_commit(mu_copied,
None,
None,
- expected_error,
- mu_copied)
+ expected_error)
# But now do the same thing via changelist filtering
svntest.main.run_svn(None, 'changelist', 'L', mu_copied, sbox.ospath('A/mu'))
@@ -2935,7 +2904,7 @@ def commit_unversioned(sbox):
sbox.build(read_only=True)
wc_dir = sbox.wc_dir
- expected_err = 'E200009: .*existing.*\' is not under version control'
+ expected_err = '.*E200009: .*existing.*\' is not under version control.*'
# Unversioned, but existing file
svntest.main.file_write(sbox.ospath('existing'), "xxxx")
@@ -2994,9 +2963,7 @@ def commit_cp_with_deep_delete(sbox):
# Commit the copy without the one dir.
svntest.actions.run_and_verify_commit(wc_dir,
expected_output,
- expected_status,
- None,
- wc_dir)
+ expected_status)
def commit_deep_deleted(sbox):
"try to commit a deep descendant of a deleted node"
@@ -3008,9 +2975,9 @@ def commit_deep_deleted(sbox):
sbox.simple_propset('k', 'v', 'AA/D/G')
# Committing some added descendant returns a proper error
- expected_err = ('svn: E200009: \'%s\' is not known to exist in the ' +
+ expected_err = ('.*svn: E200009: \'%s\' is not known to exist in the ' +
'repository and is not part of the commit, yet its ' +
- 'child \'%s\' is part of the commit') % (
+ 'child \'%s\' is part of the commit.*') % (
re.escape(os.path.abspath(sbox.ospath('AA'))),
re.escape(os.path.abspath(sbox.ospath('AA/D/G'))))