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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/RecordingImageBufferSurfaceTest.cpp

Issue 1419293005: Add assertions that the empty Platform::cryptographicallyRandomValues() overrides are not being use… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change to RELEASE_ASSERT and use base::RandBytes() in Chromium. Created 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "config.h" 5 #include "config.h"
6 #include "platform/graphics/RecordingImageBufferSurface.h" 6 #include "platform/graphics/RecordingImageBufferSurface.h"
7 7
8 #include "platform/graphics/GraphicsContext.h" 8 #include "platform/graphics/GraphicsContext.h"
9 #include "platform/graphics/ImageBuffer.h" 9 #include "platform/graphics/ImageBuffer.h"
10 #include "platform/graphics/ImageBufferClient.h" 10 #include "platform/graphics/ImageBufferClient.h"
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 } 331 }
332 332
333 private: 333 private:
334 MockWebTaskRunner m_taskRunner; 334 MockWebTaskRunner m_taskRunner;
335 TaskObserver* m_taskObserver; 335 TaskObserver* m_taskObserver;
336 }; 336 };
337 337
338 class CurrentThreadPlatformMock : public Platform { 338 class CurrentThreadPlatformMock : public Platform {
339 public: 339 public:
340 CurrentThreadPlatformMock() { } 340 CurrentThreadPlatformMock() { }
341 virtual void cryptographicallyRandomValues(unsigned char* buffer, size_t length) { ASSERT_NOT_REACHED(); } 341 virtual void cryptographicallyRandomValues(unsigned char* buffer, size_t length)
342 {
343 RELEASE_ASSERT_NOT_REACHED();
344 }
342 WebThread* currentThread() override { return &m_currentThread; } 345 WebThread* currentThread() override { return &m_currentThread; }
343 346
344 void enterRunLoop() { m_currentThread.enterRunLoop(); } 347 void enterRunLoop() { m_currentThread.enterRunLoop(); }
345 private: 348 private:
346 CurrentThreadMock m_currentThread; 349 CurrentThreadMock m_currentThread;
347 }; 350 };
348 351
349 CurrentThreadPlatformMock m_mockPlatform; 352 CurrentThreadPlatformMock m_mockPlatform;
350 Platform* m_oldPlatform; 353 Platform* m_oldPlatform;
351 }; 354 };
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
410 } 413 }
411 414
412 DEFINE_TEST_TASK_WRAPPER_CLASS(testClearRect) 415 DEFINE_TEST_TASK_WRAPPER_CLASS(testClearRect)
413 TEST_F(RecordingImageBufferSurfaceTest, testClearRect) 416 TEST_F(RecordingImageBufferSurfaceTest, testClearRect)
414 { 417 {
415 CALL_TEST_TASK_WRAPPER(testClearRect); 418 CALL_TEST_TASK_WRAPPER(testClearRect);
416 expectDisplayListEnabled(true); 419 expectDisplayListEnabled(true);
417 } 420 }
418 421
419 } // namespace blink 422 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/fonts/FontCacheTest.cpp ('k') | third_party/WebKit/Source/platform/heap/RunAllTests.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698