Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(184)

Issue 7212029: Add a browser-test for the keyboard widget. (Closed)

Created:
9 years, 5 months ago by sadrul
Modified:
9 years, 4 months ago
Reviewers:
sky
CC:
chromium-reviews, joi+watch-content_chromium.org, jam, Paweł Hajdan Jr.
Visibility:
Public.

Description

Add a browser-test for the keyboard widget. Currently it only tests the keyboard visibility. Eventually, it will have more tests for the keyboard type, size, shape etc. BUG=none TEST=KeyboardManagerTest.* Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=98109

Patch Set 1 #

Patch Set 2 : a more complicated test #

Patch Set 3 : . #

Total comments: 8

Patch Set 4 : . #

Patch Set 5 : merge #

Patch Set 6 : . #

Patch Set 7 : . #

Patch Set 8 : . #

Unified diffs Side-by-side diffs Delta from patch set Stats (+126 lines, -2 lines) Patch
M chrome/browser/ui/touch/frame/touch_browser_frame_view.cc View 1 2 3 4 1 chunk +0 lines, -1 line 0 comments Download
M chrome/browser/ui/touch/keyboard/keyboard_manager.cc View 1 2 3 4 5 2 chunks +13 lines, -1 line 0 comments Download
A chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc View 1 2 3 4 5 1 chunk +92 lines, -0 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 2 3 4 5 6 7 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/common/chrome_notification_types.h View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download
A chrome/test/data/keyboard/blank.html View 1 1 chunk +1 line, -0 lines 0 comments Download
A chrome/test/data/keyboard/focus.html View 1 1 chunk +10 lines, -0 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
sadrul
A test for http://codereview.chromium.org/7302015/
9 years, 5 months ago (2011-07-05 21:50:55 UTC) #1
sky
LGTM http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc File chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc (right): http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc#newcode15 chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc:15: KeyboardManagerTest() : InProcessBrowserTest(), put the member initialize list ...
9 years, 5 months ago (2011-07-06 14:38:31 UTC) #2
sadrul
9 years, 5 months ago (2011-07-06 16:18:19 UTC) #3
http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyb...
File chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc (right):

http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyb...
chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc:15:
KeyboardManagerTest() : InProcessBrowserTest(),
On 2011/07/06 14:38:31, sky wrote:
> put the member initialize list on the next line and indent 4.

Done.

http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyb...
chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc:19: bool
keyboard_visible() { return keyboard_visible_; }
On 2011/07/06 14:38:31, sky wrote:
> const

Done.

http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyb...
chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc:29:
registrar_.RemoveAll();
On 2011/07/06 14:38:31, sky wrote:
> This will automatically happen in the destructor. Is there really a reason you
> need it here?

By the time this happens in the destructor, the NotificationService has already
been destroyed, and this ends up causing a crash:

FATAL:notification_service.cc(71)] Check failed: HasKey(observers_[type.value],
source).
Backtrace:
        base::debug::StackTrace::StackTrace() [0x7fa0e5c2755e]
        logging::LogMessage::~LogMessage() [0x7fa0e5c4b762]
        NotificationService::RemoveObserver() [0x1d9e6d5]
        NotificationRegistrar::RemoveAll() [0x1d9cd95]
        NotificationRegistrar::~NotificationRegistrar() [0x1d9c950]
        KeyboardManagerTest::~KeyboardManagerTest() [0x94754d]

http://codereview.chromium.org/7212029/diff/5001/chrome/browser/ui/touch/keyb...
chrome/browser/ui/touch/keyboard/keyboard_manager_browsertest.cc:48: // it is
necessary to to RunAllPendingInMessageLoop each time after moving
On 2011/07/06 14:38:31, sky wrote:
> 'to to' -> 'to'

Done.

Powered by Google App Engine
This is Rietveld 408576698