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

Unified Diff: webrtc/modules/audio_processing/transient/transient_detector_unittest.cc

Issue 1698843003: Replace scoped_ptr with unique_ptr in webrtc/modules/audio_processing/transient/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: compile fix Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_processing/transient/transient_detector_unittest.cc
diff --git a/webrtc/modules/audio_processing/transient/transient_detector_unittest.cc b/webrtc/modules/audio_processing/transient/transient_detector_unittest.cc
index b60077510b4414ee31e5d3e503a277e016ed2702..18bb42e0eb6739f17b227e7379165ef4588df8f1 100644
--- a/webrtc/modules/audio_processing/transient/transient_detector_unittest.cc
+++ b/webrtc/modules/audio_processing/transient/transient_detector_unittest.cc
@@ -10,11 +10,11 @@
#include "webrtc/modules/audio_processing/transient/transient_detector.h"
+#include <memory>
#include <sstream>
#include <string>
#include "testing/gtest/include/gtest/gtest.h"
-#include "webrtc/base/scoped_ptr.h"
#include "webrtc/modules/audio_processing/transient/common.h"
#include "webrtc/modules/audio_processing/transient/file_utils.h"
#include "webrtc/system_wrappers/include/file_wrapper.h"
@@ -49,7 +49,7 @@ TEST(TransientDetectorTest, CorrectnessBasedOnFiles) {
detect_file_name << "audio_processing/transient/detect"
<< (sample_rate_hz / 1000) << "kHz";
- rtc::scoped_ptr<FileWrapper> detect_file(FileWrapper::Create());
+ std::unique_ptr<FileWrapper> detect_file(FileWrapper::Create());
detect_file->OpenFile(
test::ResourcePath(detect_file_name.str(), "dat").c_str(),
@@ -66,7 +66,7 @@ TEST(TransientDetectorTest, CorrectnessBasedOnFiles) {
audio_file_name << "audio_processing/transient/audio"
<< (sample_rate_hz / 1000) << "kHz";
- rtc::scoped_ptr<FileWrapper> audio_file(FileWrapper::Create());
+ std::unique_ptr<FileWrapper> audio_file(FileWrapper::Create());
audio_file->OpenFile(
test::ResourcePath(audio_file_name.str(), "pcm").c_str(),
@@ -78,7 +78,7 @@ TEST(TransientDetectorTest, CorrectnessBasedOnFiles) {
TransientDetector detector(sample_rate_hz);
const size_t buffer_length = sample_rate_hz * ts::kChunkSizeMs / 1000;
- rtc::scoped_ptr<float[]> buffer(new float[buffer_length]);
+ std::unique_ptr<float[]> buffer(new float[buffer_length]);
const float kTolerance = 0.02f;

Powered by Google App Engine
This is Rietveld 408576698