Author: kotkov Date: Fri Oct 14 12:53:59 2016 New Revision: 1764886 URL: http://svn.apache.org/viewvc?rev=1764886&view=rev Log: * subversion/tests/libsvn_client/conflicts-test.c (create_wc_with_file_add_vs_file_add_update_conflict): Remove this unused function.
Modified: subversion/trunk/subversion/tests/libsvn_client/conflicts-test.c Modified: subversion/trunk/subversion/tests/libsvn_client/conflicts-test.c URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/libsvn_client/conflicts-test.c?rev=1764886&r1=1764885&r2=1764886&view=diff ============================================================================== --- subversion/trunk/subversion/tests/libsvn_client/conflicts-test.c (original) +++ subversion/trunk/subversion/tests/libsvn_client/conflicts-test.c Fri Oct 14 12:53:59 2016 @@ -447,81 +447,6 @@ test_merge_incoming_added_file_replace_a return SVN_NO_ERROR; } -/* A helper function which prepares a working copy for the tests below. */ -static svn_error_t * -create_wc_with_file_add_vs_file_add_update_conflict(svn_test__sandbox_t *b) -{ - static const char *new_file_path; - svn_client_ctx_t *ctx; - svn_opt_revision_t opt_rev; - svn_client_status_t *status; - struct status_baton sb; - svn_client_conflict_t *conflict; - svn_boolean_t tree_conflicted; - - SVN_ERR(sbox_add_and_commit_greek_tree(b)); - - /* Add and commit a new file. */ - new_file_path = svn_relpath_join(trunk_path, new_file_name, b->pool); - SVN_ERR(sbox_file_write(b, new_file_path, - "This is a new file on the trunk\n")); - SVN_ERR(sbox_wc_add(b, new_file_path)); - SVN_ERR(sbox_wc_propset(b, "prop", propval_trunk, new_file_path)); - SVN_ERR(sbox_wc_commit(b, "")); - - /* Back-date the WC. */ - SVN_ERR(sbox_wc_update(b, "", 1)); - - /* Add a file which occupies the same path but has different content - * and properties. */ - SVN_ERR(sbox_file_write(b, new_file_path, - /* NB: Ensure that the file content's length differs! - * Tests are run without sleep for timestamps. */ - "This is a new file on the branch\n")); - SVN_ERR(sbox_wc_add(b, new_file_path)); - SVN_ERR(sbox_wc_propset(b, "prop", propval_branch, new_file_path)); - - /* Update the WC. - * This should raise an "incoming add vs local add" tree conflict because - * the sbox test code runs updates with 'adds_as_modifications == FALSE'. */ - SVN_ERR(sbox_wc_update(b, "", SVN_INVALID_REVNUM)); - - /* Ensure that the file has the expected status. */ - SVN_ERR(svn_test__create_client_ctx(&ctx, b, b->pool)); - opt_rev.kind = svn_opt_revision_head; - sb.result_pool = b->pool; - SVN_ERR(svn_client_status6(NULL, ctx, sbox_wc_path(b, new_file_path), - &opt_rev, svn_depth_unknown, TRUE, TRUE, - TRUE, TRUE, FALSE, TRUE, NULL, - status_func, &sb, b->pool)); - status = sb.status; - SVN_TEST_ASSERT(status->kind == svn_node_file); - SVN_TEST_ASSERT(status->versioned); - SVN_TEST_ASSERT(status->conflicted); - SVN_TEST_ASSERT(status->node_status == svn_wc_status_replaced); - SVN_TEST_ASSERT(status->text_status == svn_wc_status_modified); - SVN_TEST_ASSERT(status->prop_status == svn_wc_status_modified); - SVN_TEST_ASSERT(!status->copied); - SVN_TEST_ASSERT(!status->switched); - SVN_TEST_ASSERT(!status->file_external); - SVN_TEST_ASSERT(status->moved_from_abspath == NULL); - SVN_TEST_ASSERT(status->moved_to_abspath == NULL); - - SVN_ERR(svn_client_conflict_get(&conflict, sbox_wc_path(b, new_file_path), - ctx, b->pool, b->pool)); - - /* Ensure that the expected tree conflict is present. */ - SVN_ERR(svn_client_conflict_get_conflicted(NULL, NULL, &tree_conflicted, - conflict, b->pool, b->pool)); - SVN_TEST_ASSERT(tree_conflicted); - SVN_TEST_ASSERT(svn_client_conflict_get_local_change(conflict) == - svn_wc_conflict_reason_added); - SVN_TEST_ASSERT(svn_client_conflict_get_incoming_change(conflict) == - svn_wc_conflict_action_add); - - return SVN_NO_ERROR; -} - /* * The following tests verify resolution of "incoming dir add vs. * local dir obstruction upon merge" tree conflicts.