OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 package org.chromium.chrome.browser.payments; | 5 package org.chromium.chrome.browser.payments; |
6 | 6 |
7 import android.support.test.filters.MediumTest; | 7 import android.support.test.filters.MediumTest; |
8 | 8 |
9 import org.chromium.base.test.util.Feature; | 9 import org.chromium.base.test.util.Feature; |
10 import org.chromium.chrome.R; | 10 import org.chromium.chrome.R; |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 | 42 |
43 // Repeating a query does not count against the quota. | 43 // Repeating a query does not count against the quota. |
44 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); | 44 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); |
45 expectResultContains(new String[]{"true"}); | 45 expectResultContains(new String[]{"true"}); |
46 | 46 |
47 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); | 47 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); |
48 expectResultContains(new String[]{"true"}); | 48 expectResultContains(new String[]{"true"}); |
49 | 49 |
50 // Different queries are throttled for a period of time. | 50 // Different queries are throttled for a period of time. |
51 clickNodeAndWait("other-buy", mCanMakePaymentQueryResponded); | 51 clickNodeAndWait("other-buy", mCanMakePaymentQueryResponded); |
52 expectResultContains(new String[]{"Query quota exceeded"}); | 52 expectResultContains(new String[] {"Not allowed to check whether can mak
e payment"}); |
53 | 53 |
54 // Repeating the same query again does not count against the quota. | 54 // Repeating the same query again does not count against the quota. |
55 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); | 55 clickNodeAndWait("buy", mCanMakePaymentQueryResponded); |
56 expectResultContains(new String[]{"true"}); | 56 expectResultContains(new String[]{"true"}); |
57 } | 57 } |
58 } | 58 } |
OLD | NEW |