| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 { | 124 { |
| 125 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create(); | 125 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create(); |
| 126 EXPECT_CALL(*backend, abort(transactionId)) | 126 EXPECT_CALL(*backend, abort(transactionId)) |
| 127 .Times(1); | 127 .Times(1); |
| 128 EXPECT_CALL(*backend, close()) | 128 EXPECT_CALL(*backend, close()) |
| 129 .Times(1); | 129 .Times(1); |
| 130 IDBOpenDBRequest* request = IDBOpenDBRequest::create(getScriptState(), c
allbacks, transactionId, version); | 130 IDBOpenDBRequest* request = IDBOpenDBRequest::create(getScriptState(), c
allbacks, transactionId, version); |
| 131 EXPECT_EQ(request->readyState(), "pending"); | 131 EXPECT_EQ(request->readyState(), "pending"); |
| 132 | 132 |
| 133 getExecutionContext()->stopActiveDOMObjects(); | 133 getExecutionContext()->stopActiveDOMObjects(); |
| 134 request->onUpgradeNeeded(oldVersion, backend.release(), metadata, WebIDB
DataLossNone, String()); | 134 request->onUpgradeNeeded(oldVersion, std::move(backend), metadata, WebID
BDataLossNone, String()); |
| 135 } | 135 } |
| 136 | 136 |
| 137 { | 137 { |
| 138 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create(); | 138 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create(); |
| 139 EXPECT_CALL(*backend, close()) | 139 EXPECT_CALL(*backend, close()) |
| 140 .Times(1); | 140 .Times(1); |
| 141 IDBOpenDBRequest* request = IDBOpenDBRequest::create(getScriptState(), c
allbacks, transactionId, version); | 141 IDBOpenDBRequest* request = IDBOpenDBRequest::create(getScriptState(), c
allbacks, transactionId, version); |
| 142 EXPECT_EQ(request->readyState(), "pending"); | 142 EXPECT_EQ(request->readyState(), "pending"); |
| 143 | 143 |
| 144 getExecutionContext()->stopActiveDOMObjects(); | 144 getExecutionContext()->stopActiveDOMObjects(); |
| 145 request->onSuccess(backend.release(), metadata); | 145 request->onSuccess(std::move(backend), metadata); |
| 146 } | 146 } |
| 147 } | 147 } |
| 148 | 148 |
| 149 } // namespace | 149 } // namespace |
| 150 } // namespace blink | 150 } // namespace blink |
| OLD | NEW |