OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // History unit tests come in two flavors: | 5 // History unit tests come in two flavors: |
6 // | 6 // |
7 // 1. The more complicated style is that the unit test creates a full history | 7 // 1. The more complicated style is that the unit test creates a full history |
8 // service. This spawns a background thread for the history backend, and | 8 // service. This spawns a background thread for the history backend, and |
9 // all communication is asynchronous. This is useful for testing more | 9 // all communication is asynchronous. This is useful for testing more |
10 // complicated things or end-to-end behavior. | 10 // complicated things or end-to-end behavior. |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
54 {"FILE_FAILED", 1}, | 54 {"FILE_FAILED", 1}, |
55 {"FILE_ACCESS_DENIED", 2}, | 55 {"FILE_ACCESS_DENIED", 2}, |
56 {"FILE_NO_SPACE", 3}, | 56 {"FILE_NO_SPACE", 3}, |
57 {"FILE_NAME_TOO_LONG", 5}, | 57 {"FILE_NAME_TOO_LONG", 5}, |
58 {"FILE_TOO_LARGE", 6}, | 58 {"FILE_TOO_LARGE", 6}, |
59 {"FILE_VIRUS_INFECTED", 7}, | 59 {"FILE_VIRUS_INFECTED", 7}, |
60 {"FILE_TRANSIENT_ERROR", 10}, | 60 {"FILE_TRANSIENT_ERROR", 10}, |
61 {"FILE_BLOCKED", 11}, | 61 {"FILE_BLOCKED", 11}, |
62 {"FILE_SECURITY_CHECK_FAILED", 12}, | 62 {"FILE_SECURITY_CHECK_FAILED", 12}, |
63 {"FILE_TOO_SHORT", 13}, | 63 {"FILE_TOO_SHORT", 13}, |
| 64 {"FILE_HASH_MISMATCH", 14}, |
64 {"NETWORK_FAILED", 20}, | 65 {"NETWORK_FAILED", 20}, |
65 {"NETWORK_TIMEOUT", 21}, | 66 {"NETWORK_TIMEOUT", 21}, |
66 {"NETWORK_DISCONNECTED", 22}, | 67 {"NETWORK_DISCONNECTED", 22}, |
67 {"NETWORK_SERVER_DOWN", 23}, | 68 {"NETWORK_SERVER_DOWN", 23}, |
68 {"NETWORK_INVALID_REQUEST", 24}, | 69 {"NETWORK_INVALID_REQUEST", 24}, |
69 {"SERVER_FAILED", 30}, | 70 {"SERVER_FAILED", 30}, |
70 {"SERVER_NO_RANGE", 31}, | 71 {"SERVER_NO_RANGE", 31}, |
71 {"SERVER_PRECONDITION", 32}, | 72 {"SERVER_PRECONDITION", 32}, |
72 {"SERVER_BAD_CONTENT", 33}, | 73 {"SERVER_BAD_CONTENT", 33}, |
73 {"SERVER_UNAUTHORIZED", 34}, | 74 {"SERVER_UNAUTHORIZED", 34}, |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 } | 124 } |
124 | 125 |
125 EXPECT_TRUE(found) | 126 EXPECT_TRUE(found) |
126 << "Error \"" << cur_reason.name << "\" not found in historical list." | 127 << "Error \"" << cur_reason.name << "\" not found in historical list." |
127 << std::endl | 128 << std::endl |
128 << "Please add it."; | 129 << "Please add it."; |
129 } | 130 } |
130 } | 131 } |
131 } // namespace | 132 } // namespace |
132 } // namespace history | 133 } // namespace history |
OLD | NEW |