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

Unified Diff: ui/android/javatests/src/org/chromium/ui/picker/DateTimePickerDialogTest.java

Issue 2480203002: ui: Cleanup class/struct forward declarations (Closed)
Patch Set: Sync CL to position 430550 Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/android/javatests/src/org/chromium/ui/picker/DateTimePickerDialogTest.java
diff --git a/ui/android/javatests/src/org/chromium/ui/picker/DateTimePickerDialogTest.java b/ui/android/javatests/src/org/chromium/ui/picker/DateTimePickerDialogTest.java
deleted file mode 100644
index 251ab4dde57a72363288a2ef330d7fce06dadc87..0000000000000000000000000000000000000000
--- a/ui/android/javatests/src/org/chromium/ui/picker/DateTimePickerDialogTest.java
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-package org.chromium.ui.picker;
-
-import android.test.InstrumentationTestCase;
-import android.test.suitebuilder.annotation.SmallTest;
-import android.widget.TimePicker;
-
-/**
- * Tests for DateTimePickerDialog.
- */
-public class DateTimePickerDialogTest extends InstrumentationTestCase {
- //TODO(tkent): fix deprecation warnings crbug.com/537037
- @SuppressWarnings("deprecation")
- @SmallTest
- public void testOnTimeChanged() {
- int september = 8;
- TimePicker picker = new TimePicker(getInstrumentation().getContext());
- // 2015-09-16 00:00 UTC
- long min = 1442361600000L;
- // 2015-09-17 00:00 UTC
- long max = 1442448000000L;
-
- // Test a value near to the minimum.
- picker.setCurrentHour(1);
- picker.setCurrentMinute(30);
- DateTimePickerDialog.onTimeChangedInternal(2015, september, 16, picker, min, max);
- assertEquals(1, picker.getCurrentHour().intValue());
- assertEquals(30, picker.getCurrentMinute().intValue());
-
- // Test a value near to the maximum.
- picker.setCurrentHour(22);
- picker.setCurrentMinute(56);
- DateTimePickerDialog.onTimeChangedInternal(2015, september, 16, picker, min, max);
- assertEquals(22, picker.getCurrentHour().intValue());
- assertEquals(56, picker.getCurrentMinute().intValue());
-
- // Clamping.
- picker.setCurrentHour(23);
- picker.setCurrentMinute(56);
- // 2015-09-16 23:30 UTC
- max = 1442446200000L;
- DateTimePickerDialog.onTimeChangedInternal(2015, september, 16, picker, min, max);
- assertEquals(23, picker.getCurrentHour().intValue());
- assertEquals(30, picker.getCurrentMinute().intValue());
- }
-}

Powered by Google App Engine
This is Rietveld 408576698