New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 642128 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android , All
Pri: 3
Type: Bug



Sign in to add a comment

BookmarksTests expects ordered sync items, but order is not being explicitly set.

Project Member Reported by rogerm@chromium.org, Aug 29 2016

Issue description

BookmarksTest.testDownloadMovedBookmark() expects that sync returns newly created items in LIFO order.

https://cs.chromium.org/chromium/src/chrome/android/sync_shell/javatests/src/org/chromium/chrome/browser/sync/BookmarksTest.java?rcl=0&l=163

Enabling autofill profile de-duplication, which is not otherwise expected to interact with this test, causes the ordering expectation to no longer be satisfied on re-runs of the test on a given machine.

This behaviour is only observed consistently on Android, though presumably it could affect other platforms.

A brief investigation suggests that the order is not explicitly being set up correctly.

zea@chromium.org wrote:

    Looking at bookmark_entity_builder.cc, it seems like we're not
    explicitly setting the position when we build the bookmark
    entity. I think it's backed by a randomly generated GUID (see
    entity_builder_factory.cc), which might explain why it only
    changes on subsequent runs.

TODOs:

    * Temporarily modify the test code to be order-insensitive
    * Update the code explicitly set item position(s)
    * Update the test(s) to validate item positions

Related bugs:

    * http://crbug/640669
 

Comment 1 by rogerm@chromium.org, Aug 29 2016

Summary: BookmarksTests expects ordered sync items, but order is not being explicitly set. (was: BookmarksTests expect ordered sync items, but order is not being explicitly set.)

Comment 2 by rogerm@chromium.org, Aug 30 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/778c94f05935d22b8e0555616d0faaf277ad5b7a

commit 778c94f05935d22b8e0555616d0faaf277ad5b7a
Author: rogerm <rogerm@chromium.org>
Date: Tue Aug 30 21:21:38 2016

Fix BookmarksTest#testDownloadMovedBookmark to be insensitive to item order.

BUG=620414,   640669  ,  642128 

Review-Url: https://codereview.chromium.org/2289803002
Cr-Commit-Position: refs/heads/master@{#415430}

[modify] https://crrev.com/778c94f05935d22b8e0555616d0faaf277ad5b7a/chrome/android/sync_shell/javatests/src/org/chromium/chrome/browser/sync/BookmarksTest.java

Comment 3 by rogerm@chromium.org, Aug 30 2016

Description: Show this description

Comment 4 by rogerm@chromium.org, Aug 30 2016

Description: Show this description
Status: Assigned (was: Untriaged)

Comment 6 by zea@chromium.org, Jan 17 2018

Status: Archived (was: Assigned)

Sign in to add a comment