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

Side by Side Diff: Source/modules/indexeddb/IDBRequestTest.cpp

Issue 135653002: Update modules classes to use OVERRIDE / FINAL when needed (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove change to web/ Created 6 years, 11 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/modules/indexeddb/IDBRequest.h ('k') | Source/modules/indexeddb/IDBTransaction.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 23 matching lines...) Expand all
34 #include "modules/indexeddb/IDBOpenDBRequest.h" 34 #include "modules/indexeddb/IDBOpenDBRequest.h"
35 #include "platform/SharedBuffer.h" 35 #include "platform/SharedBuffer.h"
36 #include "public/platform/WebIDBDatabase.h" 36 #include "public/platform/WebIDBDatabase.h"
37 #include "wtf/PassOwnPtr.h" 37 #include "wtf/PassOwnPtr.h"
38 #include <gtest/gtest.h> 38 #include <gtest/gtest.h>
39 39
40 using namespace WebCore; 40 using namespace WebCore;
41 41
42 namespace { 42 namespace {
43 43
44 class NullEventQueue : public EventQueue { 44 class NullEventQueue FINAL : public EventQueue {
45 public: 45 public:
46 NullEventQueue() { } 46 NullEventQueue() { }
47 virtual ~NullEventQueue() { } 47 virtual ~NullEventQueue() { }
48 virtual bool enqueueEvent(PassRefPtr<Event>) OVERRIDE { return true; } 48 virtual bool enqueueEvent(PassRefPtr<Event>) OVERRIDE { return true; }
49 virtual bool cancelEvent(Event*) OVERRIDE { return true; } 49 virtual bool cancelEvent(Event*) OVERRIDE { return true; }
50 virtual void close() OVERRIDE { } 50 virtual void close() OVERRIDE { }
51 }; 51 };
52 52
53 class NullExecutionContext : public ExecutionContext, public RefCounted<NullExec utionContext> { 53 class NullExecutionContext FINAL : public ExecutionContext, public RefCounted<Nu llExecutionContext> {
54 public: 54 public:
55 using RefCounted<NullExecutionContext>::ref; 55 using RefCounted<NullExecutionContext>::ref;
56 using RefCounted<NullExecutionContext>::deref; 56 using RefCounted<NullExecutionContext>::deref;
57 57
58 virtual void refExecutionContext() OVERRIDE { ref(); } 58 virtual void refExecutionContext() OVERRIDE { ref(); }
59 virtual void derefExecutionContext() OVERRIDE { deref(); } 59 virtual void derefExecutionContext() OVERRIDE { deref(); }
60 virtual EventQueue* eventQueue() const OVERRIDE { return m_queue.get(); } 60 virtual EventQueue* eventQueue() const OVERRIDE { return m_queue.get(); }
61 61
62 NullExecutionContext(); 62 NullExecutionContext();
63 private: 63 private:
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create(); 169 OwnPtr<MockWebIDBDatabase> backend = MockWebIDBDatabase::create();
170 RefPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(executionCon text(), callbacks, transactionId, version); 170 RefPtr<IDBOpenDBRequest> request = IDBOpenDBRequest::create(executionCon text(), callbacks, transactionId, version);
171 EXPECT_EQ(request->readyState(), "pending"); 171 EXPECT_EQ(request->readyState(), "pending");
172 172
173 executionContext()->stopActiveDOMObjects(); 173 executionContext()->stopActiveDOMObjects();
174 request->onSuccess(backend.release(), metadata); 174 request->onSuccess(backend.release(), metadata);
175 } 175 }
176 } 176 }
177 177
178 } // namespace 178 } // namespace
OLDNEW
« no previous file with comments | « Source/modules/indexeddb/IDBRequest.h ('k') | Source/modules/indexeddb/IDBTransaction.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698