summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJames Zern <jzern@google.com>2018-12-06 23:58:37 -0800
committerJames Zern <jzern@google.com>2018-12-07 17:55:21 -0800
commit8f03f719af125250775207afe35c27530cf1326c (patch)
treed2b37542707131e4f93c190e79e409b0c8abfd65 /test
parent418acaa0bd06e0666d5a55743e3a85b83c759619 (diff)
downloadlibvpx-8f03f719af125250775207afe35c27530cf1326c.tar
libvpx-8f03f719af125250775207afe35c27530cf1326c.tar.gz
libvpx-8f03f719af125250775207afe35c27530cf1326c.tar.bz2
libvpx-8f03f719af125250775207afe35c27530cf1326c.zip
test/*: use std::*tuple
since: 77fa51003 Replace deprecated scoped_ptr with unique_ptr c++11 has been required so <tuple> is safe to use Change-Id: I873cb953104b361a8503b5839a3372ce2b99e73c
Diffstat (limited to 'test')
-rw-r--r--test/add_noise_test.cc6
-rw-r--r--test/avg_test.cc13
-rw-r--r--test/blockiness_test.cc5
-rw-r--r--test/codec_factory.h12
-rw-r--r--test/consistency_test.cc5
-rw-r--r--test/convolve_test.cc5
-rw-r--r--test/dct16x16_test.cc11
-rw-r--r--test/dct32x32_test.cc5
-rw-r--r--test/dct_partial_test.cc6
-rw-r--r--test/dct_test.cc5
-rw-r--r--test/decode_corrupted.cc4
-rw-r--r--test/decode_perf_test.cc6
-rw-r--r--test/fdct8x8_test.cc9
-rw-r--r--test/lpf_test.cc7
-rw-r--r--test/partial_idct_test.cc8
-rw-r--r--test/predict_test.cc5
-rw-r--r--test/quantize_test.cc5
-rw-r--r--test/sum_squares_test.cc5
-rw-r--r--test/superframe_test.cc6
-rw-r--r--test/test_vector_test.cc8
-rw-r--r--test/util.h4
-rw-r--r--test/vp9_block_error_test.cc5
-rw-r--r--test/vp9_denoiser_test.cc6
-rw-r--r--test/vp9_quantize_test.cc7
24 files changed, 92 insertions, 66 deletions
diff --git a/test/add_noise_test.cc b/test/add_noise_test.cc
index be56dd77b..0d1893c52 100644
--- a/test/add_noise_test.cc
+++ b/test/add_noise_test.cc
@@ -8,6 +8,8 @@
* be found in the AUTHORS file in the root of the source tree.
*/
#include <math.h>
+#include <tuple>
+
#include "test/clear_system_state.h"
#include "test/register_state_check.h"
#include "test/util.h"
@@ -26,7 +28,7 @@ typedef void (*AddNoiseFunc)(uint8_t *start, const int8_t *noise,
int blackclamp, int whiteclamp, int width,
int height, int pitch);
-typedef ::testing::tuple<double, AddNoiseFunc> AddNoiseTestFPParam;
+typedef std::tuple<double, AddNoiseFunc> AddNoiseTestFPParam;
class AddNoiseTest : public ::testing::Test,
public ::testing::WithParamInterface<AddNoiseTestFPParam> {
@@ -125,7 +127,7 @@ TEST_P(AddNoiseTest, CheckCvsAssembly) {
vpx_free(s);
}
-using ::testing::make_tuple;
+using std::make_tuple;
INSTANTIATE_TEST_CASE_P(
C, AddNoiseTest,
diff --git a/test/avg_test.cc b/test/avg_test.cc
index 5455f05ed..9c242c24f 100644
--- a/test/avg_test.cc
+++ b/test/avg_test.cc
@@ -11,6 +11,7 @@
#include <limits.h>
#include <stdio.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -95,7 +96,7 @@ class AverageTestBase : public ::testing::Test {
};
typedef unsigned int (*AverageFunction)(const uint8_t *s, int pitch);
-typedef ::testing::tuple<int, int, int, int, AverageFunction> AvgFunc;
+typedef std::tuple<int, int, int, int, AverageFunction> AvgFunc;
class AverageTest : public AverageTestBase<uint8_t>,
public ::testing::WithParamInterface<AvgFunc> {
@@ -154,7 +155,7 @@ class AverageTestHBD : public AverageTestBase<uint16_t>,
typedef void (*IntProRowFunc)(int16_t hbuf[16], uint8_t const *ref,
const int ref_stride, const int height);
-typedef ::testing::tuple<int, IntProRowFunc, IntProRowFunc> IntProRowParam;
+typedef std::tuple<int, IntProRowFunc, IntProRowFunc> IntProRowParam;
class IntProRowTest : public AverageTestBase<uint8_t>,
public ::testing::WithParamInterface<IntProRowParam> {
@@ -202,7 +203,7 @@ class IntProRowTest : public AverageTestBase<uint8_t>,
typedef int16_t (*IntProColFunc)(uint8_t const *ref, const int width);
-typedef ::testing::tuple<int, IntProColFunc, IntProColFunc> IntProColParam;
+typedef std::tuple<int, IntProColFunc, IntProColFunc> IntProColParam;
class IntProColTest : public AverageTestBase<uint8_t>,
public ::testing::WithParamInterface<IntProColParam> {
@@ -227,7 +228,7 @@ class IntProColTest : public AverageTestBase<uint8_t>,
};
typedef int (*SatdFunc)(const tran_low_t *coeffs, int length);
-typedef ::testing::tuple<int, SatdFunc> SatdTestParam;
+typedef std::tuple<int, SatdFunc> SatdTestParam;
class SatdTest : public ::testing::Test,
public ::testing::WithParamInterface<SatdTestParam> {
@@ -275,7 +276,7 @@ class SatdTest : public ::testing::Test,
typedef int64_t (*BlockErrorFunc)(const tran_low_t *coeff,
const tran_low_t *dqcoeff, int block_size);
-typedef ::testing::tuple<int, BlockErrorFunc> BlockErrorTestFPParam;
+typedef std::tuple<int, BlockErrorFunc> BlockErrorTestFPParam;
class BlockErrorTestFP
: public ::testing::Test,
@@ -493,7 +494,7 @@ TEST_P(BlockErrorTestFP, DISABLED_Speed) {
printf("blocksize: %4d time: %4d us\n", blocksize, elapsed_time);
}
-using ::testing::make_tuple;
+using std::make_tuple;
INSTANTIATE_TEST_CASE_P(
C, AverageTest,
diff --git a/test/blockiness_test.cc b/test/blockiness_test.cc
index c6a3be1a3..38b4b5886 100644
--- a/test/blockiness_test.cc
+++ b/test/blockiness_test.cc
@@ -11,6 +11,7 @@
#include <limits.h>
#include <stdio.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -141,7 +142,7 @@ class BlockinessTestBase : public ::testing::Test {
};
#if CONFIG_VP9_ENCODER
-typedef ::testing::tuple<int, int> BlockinessParam;
+typedef std::tuple<int, int> BlockinessParam;
class BlockinessVP9Test
: public BlockinessTestBase,
public ::testing::WithParamInterface<BlockinessParam> {
@@ -208,7 +209,7 @@ TEST_P(BlockinessVP9Test, WorstCaseBlockiness) {
}
#endif // CONFIG_VP9_ENCODER
-using ::testing::make_tuple;
+using std::make_tuple;
//------------------------------------------------------------------------------
// C functions
diff --git a/test/codec_factory.h b/test/codec_factory.h
index 2bfb47360..17c9512ca 100644
--- a/test/codec_factory.h
+++ b/test/codec_factory.h
@@ -10,6 +10,8 @@
#ifndef VPX_TEST_CODEC_FACTORY_H_
#define VPX_TEST_CODEC_FACTORY_H_
+#include <tuple>
+
#include "./vpx_config.h"
#include "vpx/vpx_decoder.h"
#include "vpx/vpx_encoder.h"
@@ -53,22 +55,22 @@ class CodecFactory {
template <class T1>
class CodecTestWithParam
: public ::testing::TestWithParam<
- ::testing::tuple<const libvpx_test::CodecFactory *, T1> > {};
+ std::tuple<const libvpx_test::CodecFactory *, T1> > {};
template <class T1, class T2>
class CodecTestWith2Params
: public ::testing::TestWithParam<
- ::testing::tuple<const libvpx_test::CodecFactory *, T1, T2> > {};
+ std::tuple<const libvpx_test::CodecFactory *, T1, T2> > {};
template <class T1, class T2, class T3>
class CodecTestWith3Params
: public ::testing::TestWithParam<
- ::testing::tuple<const libvpx_test::CodecFactory *, T1, T2, T3> > {};
+ std::tuple<const libvpx_test::CodecFactory *, T1, T2, T3> > {};
template <class T1, class T2, class T3, class T4>
class CodecTestWith4Params
- : public ::testing::TestWithParam< ::testing::tuple<
- const libvpx_test::CodecFactory *, T1, T2, T3, T4> > {};
+ : public ::testing::TestWithParam<
+ std::tuple<const libvpx_test::CodecFactory *, T1, T2, T3, T4> > {};
/*
* VP8 Codec Definitions
diff --git a/test/consistency_test.cc b/test/consistency_test.cc
index f6660daaa..61e15f73b 100644
--- a/test/consistency_test.cc
+++ b/test/consistency_test.cc
@@ -11,6 +11,7 @@
#include <limits.h>
#include <stdio.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -127,7 +128,7 @@ class ConsistencyTestBase : public ::testing::Test {
};
#if CONFIG_VP9_ENCODER
-typedef ::testing::tuple<int, int> ConsistencyParam;
+typedef std::tuple<int, int> ConsistencyParam;
class ConsistencyVP9Test
: public ConsistencyTestBase,
public ::testing::WithParamInterface<ConsistencyParam> {
@@ -198,7 +199,7 @@ TEST_P(ConsistencyVP9Test, ConsistencyIsZero) {
}
#endif // CONFIG_VP9_ENCODER
-using ::testing::make_tuple;
+using std::make_tuple;
//------------------------------------------------------------------------------
// C functions
diff --git a/test/convolve_test.cc b/test/convolve_test.cc
index 0b718a511..02cc7ff5c 100644
--- a/test/convolve_test.cc
+++ b/test/convolve_test.cc
@@ -9,6 +9,7 @@
*/
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -77,7 +78,7 @@ struct ConvolveFunctions {
int use_highbd_; // 0 if high bitdepth not used, else the actual bit depth.
};
-typedef ::testing::tuple<int, int, const ConvolveFunctions *> ConvolveParam;
+typedef std::tuple<int, int, const ConvolveFunctions *> ConvolveParam;
#define ALL_SIZES(convolve_fn) \
make_tuple(4, 4, &convolve_fn), make_tuple(8, 4, &convolve_fn), \
@@ -1113,7 +1114,7 @@ TEST_P(ConvolveTest, CheckScalingFiltering) {
}
#endif
-using ::testing::make_tuple;
+using std::make_tuple;
#if CONFIG_VP9_HIGHBITDEPTH
#define WRAP(func, bd) \
diff --git a/test/dct16x16_test.cc b/test/dct16x16_test.cc
index 872824188..9ccf2b84f 100644
--- a/test/dct16x16_test.cc
+++ b/test/dct16x16_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -229,11 +230,9 @@ typedef void (*FhtFunc)(const int16_t *in, tran_low_t *out, int stride,
typedef void (*IhtFunc)(const tran_low_t *in, uint8_t *out, int stride,
int tx_type);
-typedef ::testing::tuple<FdctFunc, IdctFunc, int, vpx_bit_depth_t>
- Dct16x16Param;
-typedef ::testing::tuple<FhtFunc, IhtFunc, int, vpx_bit_depth_t> Ht16x16Param;
-typedef ::testing::tuple<IdctFunc, IdctFunc, int, vpx_bit_depth_t>
- Idct16x16Param;
+typedef std::tuple<FdctFunc, IdctFunc, int, vpx_bit_depth_t> Dct16x16Param;
+typedef std::tuple<FhtFunc, IhtFunc, int, vpx_bit_depth_t> Ht16x16Param;
+typedef std::tuple<IdctFunc, IdctFunc, int, vpx_bit_depth_t> Idct16x16Param;
void fdct16x16_ref(const int16_t *in, tran_low_t *out, int stride,
int /*tx_type*/) {
@@ -745,7 +744,7 @@ TEST_P(InvTrans16x16DCT, CompareReference) {
CompareInvReference(ref_txfm_, thresh_);
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if CONFIG_VP9_HIGHBITDEPTH
INSTANTIATE_TEST_CASE_P(
diff --git a/test/dct32x32_test.cc b/test/dct32x32_test.cc
index dd902f584..94d6b37fa 100644
--- a/test/dct32x32_test.cc
+++ b/test/dct32x32_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -67,7 +68,7 @@ void reference_32x32_dct_2d(const int16_t input[kNumCoeffs],
typedef void (*FwdTxfmFunc)(const int16_t *in, tran_low_t *out, int stride);
typedef void (*InvTxfmFunc)(const tran_low_t *in, uint8_t *out, int stride);
-typedef ::testing::tuple<FwdTxfmFunc, InvTxfmFunc, int, vpx_bit_depth_t>
+typedef std::tuple<FwdTxfmFunc, InvTxfmFunc, int, vpx_bit_depth_t>
Trans32x32Param;
#if CONFIG_VP9_HIGHBITDEPTH
@@ -313,7 +314,7 @@ TEST_P(Trans32x32Test, InverseAccuracy) {
}
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if CONFIG_VP9_HIGHBITDEPTH
INSTANTIATE_TEST_CASE_P(
diff --git a/test/dct_partial_test.cc b/test/dct_partial_test.cc
index dd040d52a..c889e92d7 100644
--- a/test/dct_partial_test.cc
+++ b/test/dct_partial_test.cc
@@ -11,8 +11,8 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
-
#include <limits>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -28,8 +28,8 @@
using libvpx_test::ACMRandom;
using libvpx_test::Buffer;
-using ::testing::make_tuple;
-using ::testing::tuple;
+using std::make_tuple;
+using std::tuple;
namespace {
typedef void (*PartialFdctFunc)(const int16_t *in, tran_low_t *out, int stride);
diff --git a/test/dct_test.cc b/test/dct_test.cc
index 5b5ce4001..6053aee54 100644
--- a/test/dct_test.cc
+++ b/test/dct_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -28,8 +29,8 @@
using libvpx_test::ACMRandom;
using libvpx_test::Buffer;
-using ::testing::make_tuple;
-using ::testing::tuple;
+using std::make_tuple;
+using std::tuple;
namespace {
typedef void (*FdctFunc)(const int16_t *in, tran_low_t *out, int stride);
diff --git a/test/decode_corrupted.cc b/test/decode_corrupted.cc
index b44c378b9..b1495ce89 100644
--- a/test/decode_corrupted.cc
+++ b/test/decode_corrupted.cc
@@ -8,6 +8,8 @@
* be found in the AUTHORS file in the root of the source tree.
*/
+#include <tuple>
+
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
@@ -21,7 +23,7 @@ namespace {
class DecodeCorruptedFrameTest
: public ::libvpx_test::EncoderTest,
public ::testing::TestWithParam<
- ::testing::tuple<const libvpx_test::CodecFactory *> > {
+ std::tuple<const libvpx_test::CodecFactory *> > {
public:
DecodeCorruptedFrameTest() : EncoderTest(GET_PARAM(0)) {}
diff --git a/test/decode_perf_test.cc b/test/decode_perf_test.cc
index fed09de98..aecdd3e99 100644
--- a/test/decode_perf_test.cc
+++ b/test/decode_perf_test.cc
@@ -9,6 +9,8 @@
*/
#include <string>
+#include <tuple>
+
#include "test/codec_factory.h"
#include "test/decode_test_driver.h"
#include "test/encode_test_driver.h"
@@ -21,7 +23,7 @@
#include "./ivfenc.h"
#include "./vpx_version.h"
-using ::testing::make_tuple;
+using std::make_tuple;
namespace {
@@ -34,7 +36,7 @@ const char kNewEncodeOutputFile[] = "new_encode.ivf";
/*
DecodePerfTest takes a tuple of filename + number of threads to decode with
*/
-typedef ::testing::tuple<const char *, unsigned> DecodePerfParam;
+typedef std::tuple<const char *, unsigned> DecodePerfParam;
const DecodePerfParam kVP9DecodePerfVectors[] = {
make_tuple("vp90-2-bbb_426x240_tile_1x1_180kbps.webm", 1),
diff --git a/test/fdct8x8_test.cc b/test/fdct8x8_test.cc
index a86d9e33a..244b9740b 100644
--- a/test/fdct8x8_test.cc
+++ b/test/fdct8x8_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -43,9 +44,9 @@ typedef void (*FhtFunc)(const int16_t *in, tran_low_t *out, int stride,
typedef void (*IhtFunc)(const tran_low_t *in, uint8_t *out, int stride,
int tx_type);
-typedef ::testing::tuple<FdctFunc, IdctFunc, int, vpx_bit_depth_t> Dct8x8Param;
-typedef ::testing::tuple<FhtFunc, IhtFunc, int, vpx_bit_depth_t> Ht8x8Param;
-typedef ::testing::tuple<IdctFunc, IdctFunc, int, vpx_bit_depth_t> Idct8x8Param;
+typedef std::tuple<FdctFunc, IdctFunc, int, vpx_bit_depth_t> Dct8x8Param;
+typedef std::tuple<FhtFunc, IhtFunc, int, vpx_bit_depth_t> Ht8x8Param;
+typedef std::tuple<IdctFunc, IdctFunc, int, vpx_bit_depth_t> Idct8x8Param;
void reference_8x8_dct_1d(const double in[8], double out[8]) {
const double kInvSqrt2 = 0.707106781186547524400844362104;
@@ -628,7 +629,7 @@ TEST_P(InvTrans8x8DCT, CompareReference) {
CompareInvReference(ref_txfm_, thresh_);
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if CONFIG_VP9_HIGHBITDEPTH
INSTANTIATE_TEST_CASE_P(
diff --git a/test/lpf_test.cc b/test/lpf_test.cc
index 1977623ea..dfdd51599 100644
--- a/test/lpf_test.cc
+++ b/test/lpf_test.cc
@@ -11,6 +11,7 @@
#include <cmath>
#include <cstdlib>
#include <string>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -56,8 +57,8 @@ typedef void (*dual_loop_op_t)(Pixel *s, int p, const uint8_t *blimit0,
const uint8_t *thresh1);
#endif // CONFIG_VP9_HIGHBITDEPTH
-typedef ::testing::tuple<loop_op_t, loop_op_t, int> loop8_param_t;
-typedef ::testing::tuple<dual_loop_op_t, dual_loop_op_t, int> dualloop8_param_t;
+typedef std::tuple<loop_op_t, loop_op_t, int> loop8_param_t;
+typedef std::tuple<dual_loop_op_t, dual_loop_op_t, int> dualloop8_param_t;
void InitInput(Pixel *s, Pixel *ref_s, ACMRandom *rnd, const uint8_t limit,
const int mask, const int32_t p, const int i) {
@@ -402,7 +403,7 @@ TEST_P(Loop8Test9Param, ValueCheck) {
<< "First failed at test case " << first_failure;
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if HAVE_SSE2
#if CONFIG_VP9_HIGHBITDEPTH
diff --git a/test/partial_idct_test.cc b/test/partial_idct_test.cc
index 6fd4061b5..e66a695eb 100644
--- a/test/partial_idct_test.cc
+++ b/test/partial_idct_test.cc
@@ -11,8 +11,8 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
-
#include <limits>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -51,8 +51,8 @@ void highbd_wrapper(const tran_low_t *in, uint8_t *out, int stride, int bd) {
}
#endif
-typedef ::testing::tuple<FwdTxfmFunc, InvTxfmWithBdFunc, InvTxfmWithBdFunc,
- TX_SIZE, int, int, int>
+typedef std::tuple<FwdTxfmFunc, InvTxfmWithBdFunc, InvTxfmWithBdFunc, TX_SIZE,
+ int, int, int>
PartialInvTxfmParam;
const int kMaxNumCoeffs = 1024;
const int kCountTestBlock = 1000;
@@ -324,7 +324,7 @@ TEST_P(PartialIDctTest, DISABLED_Speed) {
<< "Error: partial inverse transform produces different results";
}
-using ::testing::make_tuple;
+using std::make_tuple;
const PartialInvTxfmParam c_partial_idct_tests[] = {
#if CONFIG_VP9_HIGHBITDEPTH
diff --git a/test/predict_test.cc b/test/predict_test.cc
index 6420794ff..d40d9c755 100644
--- a/test/predict_test.cc
+++ b/test/predict_test.cc
@@ -10,6 +10,7 @@
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -27,13 +28,13 @@
namespace {
using libvpx_test::ACMRandom;
-using ::testing::make_tuple;
+using std::make_tuple;
typedef void (*PredictFunc)(uint8_t *src_ptr, int src_pixels_per_line,
int xoffset, int yoffset, uint8_t *dst_ptr,
int dst_pitch);
-typedef ::testing::tuple<int, int, PredictFunc> PredictParam;
+typedef std::tuple<int, int, PredictFunc> PredictParam;
class PredictTestBase : public AbstractBench,
public ::testing::TestWithParam<PredictParam> {
diff --git a/test/quantize_test.cc b/test/quantize_test.cc
index e06241ab8..1415ce18e 100644
--- a/test/quantize_test.cc
+++ b/test/quantize_test.cc
@@ -9,6 +9,7 @@
*/
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -33,10 +34,10 @@ const int kNumBlockEntries = 16;
typedef void (*VP8Quantize)(BLOCK *b, BLOCKD *d);
-typedef ::testing::tuple<VP8Quantize, VP8Quantize> VP8QuantizeParam;
+typedef std::tuple<VP8Quantize, VP8Quantize> VP8QuantizeParam;
using libvpx_test::ACMRandom;
-using ::testing::make_tuple;
+using std::make_tuple;
// Create and populate a VP8_COMP instance which has a complete set of
// quantization inputs as well as a second MACROBLOCKD for output.
diff --git a/test/sum_squares_test.cc b/test/sum_squares_test.cc
index e211fb4d8..d2c70f4d4 100644
--- a/test/sum_squares_test.cc
+++ b/test/sum_squares_test.cc
@@ -11,6 +11,7 @@
#include <cmath>
#include <cstdlib>
#include <string>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -28,7 +29,7 @@ namespace {
const int kNumIterations = 10000;
typedef uint64_t (*SSI16Func)(const int16_t *src, int stride, int size);
-typedef ::testing::tuple<SSI16Func, SSI16Func> SumSquaresParam;
+typedef std::tuple<SSI16Func, SSI16Func> SumSquaresParam;
class SumSquaresTest : public ::testing::TestWithParam<SumSquaresParam> {
public:
@@ -102,7 +103,7 @@ TEST_P(SumSquaresTest, ExtremeValues) {
}
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if HAVE_NEON
INSTANTIATE_TEST_CASE_P(
diff --git a/test/superframe_test.cc b/test/superframe_test.cc
index d913871c5..8c8d1ae29 100644
--- a/test/superframe_test.cc
+++ b/test/superframe_test.cc
@@ -8,6 +8,8 @@
* be found in the AUTHORS file in the root of the source tree.
*/
#include <climits>
+#include <tuple>
+
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
#include "test/encode_test_driver.h"
@@ -18,7 +20,7 @@ namespace {
const int kTestMode = 0;
-typedef ::testing::tuple<libvpx_test::TestMode, int> SuperframeTestParam;
+typedef std::tuple<libvpx_test::TestMode, int> SuperframeTestParam;
class SuperframeTest
: public ::libvpx_test::EncoderTest,
@@ -31,7 +33,7 @@ class SuperframeTest
virtual void SetUp() {
InitializeConfig();
const SuperframeTestParam input = GET_PARAM(1);
- const libvpx_test::TestMode mode = ::testing::get<kTestMode>(input);
+ const libvpx_test::TestMode mode = std::get<kTestMode>(input);
SetMode(mode);
sf_count_ = 0;
sf_count_max_ = INT_MAX;
diff --git a/test/test_vector_test.cc b/test/test_vector_test.cc
index c4a6359eb..f3e585dc9 100644
--- a/test/test_vector_test.cc
+++ b/test/test_vector_test.cc
@@ -13,6 +13,8 @@
#include <memory>
#include <set>
#include <string>
+#include <tuple>
+
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "../tools_common.h"
#include "./vpx_config.h"
@@ -32,7 +34,7 @@ namespace {
const int kThreads = 0;
const int kFileName = 1;
-typedef ::testing::tuple<int, const char *> DecodeParam;
+typedef std::tuple<int, const char *> DecodeParam;
class TestVectorTest : public ::libvpx_test::DecoderTest,
public ::libvpx_test::CodecTestWithParam<DecodeParam> {
@@ -89,12 +91,12 @@ class TestVectorTest : public ::libvpx_test::DecoderTest,
// the test failed.
TEST_P(TestVectorTest, MD5Match) {
const DecodeParam input = GET_PARAM(1);
- const std::string filename = ::testing::get<kFileName>(input);
+ const std::string filename = std::get<kFileName>(input);
vpx_codec_flags_t flags = 0;
vpx_codec_dec_cfg_t cfg = vpx_codec_dec_cfg_t();
char str[256];
- cfg.threads = ::testing::get<kThreads>(input);
+ cfg.threads = std::get<kThreads>(input);
snprintf(str, sizeof(str) / sizeof(str[0]) - 1, "file: %s threads: %d",
filename.c_str(), cfg.threads);
diff --git a/test/util.h b/test/util.h
index 4392188d7..985f48709 100644
--- a/test/util.h
+++ b/test/util.h
@@ -13,11 +13,13 @@
#include <stdio.h>
#include <math.h>
+#include <tuple>
+
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "vpx/vpx_image.h"
// Macros
-#define GET_PARAM(k) ::testing::get<k>(GetParam())
+#define GET_PARAM(k) std::get<k>(GetParam())
inline double compute_psnr(const vpx_image_t *img1, const vpx_image_t *img2) {
assert((img1->fmt == img2->fmt) && (img1->d_w == img2->d_w) &&
diff --git a/test/vp9_block_error_test.cc b/test/vp9_block_error_test.cc
index fa9b6a660..71a0686d7 100644
--- a/test/vp9_block_error_test.cc
+++ b/test/vp9_block_error_test.cc
@@ -11,6 +11,7 @@
#include <cmath>
#include <cstdlib>
#include <string>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -35,7 +36,7 @@ typedef int64_t (*HBDBlockErrorFunc)(const tran_low_t *coeff,
intptr_t block_size, int64_t *ssz,
int bps);
-typedef ::testing::tuple<HBDBlockErrorFunc, HBDBlockErrorFunc, vpx_bit_depth_t>
+typedef std::tuple<HBDBlockErrorFunc, HBDBlockErrorFunc, vpx_bit_depth_t>
BlockErrorParam;
typedef int64_t (*BlockErrorFunc)(const tran_low_t *coeff,
@@ -168,7 +169,7 @@ TEST_P(BlockErrorTest, ExtremeValues) {
<< "First failed at test case " << first_failure;
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if HAVE_SSE2
const BlockErrorParam sse2_block_error_tests[] = {
diff --git a/test/vp9_denoiser_test.cc b/test/vp9_denoiser_test.cc
index e3a057bff..47fa587fc 100644
--- a/test/vp9_denoiser_test.cc
+++ b/test/vp9_denoiser_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/acm_random.h"
@@ -35,8 +36,7 @@ typedef int (*Vp9DenoiserFilterFunc)(const uint8_t *sig, int sig_stride,
uint8_t *avg, int avg_stride,
int increase_denoising, BLOCK_SIZE bs,
int motion_magnitude);
-typedef ::testing::tuple<Vp9DenoiserFilterFunc, BLOCK_SIZE>
- VP9DenoiserTestParam;
+typedef std::tuple<Vp9DenoiserFilterFunc, BLOCK_SIZE> VP9DenoiserTestParam;
class VP9DenoiserTest
: public ::testing::Test,
@@ -100,7 +100,7 @@ TEST_P(VP9DenoiserTest, BitexactCheck) {
}
}
-using ::testing::make_tuple;
+using std::make_tuple;
// Test for all block size.
#if HAVE_SSE2
diff --git a/test/vp9_quantize_test.cc b/test/vp9_quantize_test.cc
index 280d55847..cce6b6f19 100644
--- a/test/vp9_quantize_test.cc
+++ b/test/vp9_quantize_test.cc
@@ -11,6 +11,7 @@
#include <math.h>
#include <stdlib.h>
#include <string.h>
+#include <tuple>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -43,8 +44,8 @@ typedef void (*QuantizeFunc)(const tran_low_t *coeff, intptr_t count,
tran_low_t *dqcoeff, const int16_t *dequant,
uint16_t *eob, const int16_t *scan,
const int16_t *iscan);
-typedef ::testing::tuple<QuantizeFunc, QuantizeFunc, vpx_bit_depth_t,
- int /*max_size*/, bool /*is_fp*/>
+typedef std::tuple<QuantizeFunc, QuantizeFunc, vpx_bit_depth_t,
+ int /*max_size*/, bool /*is_fp*/>
QuantizeParam;
// Wrapper for FP version which does not use zbin or quant_shift.
@@ -462,7 +463,7 @@ TEST_P(VP9QuantizeTest, DISABLED_Speed) {
}
}
-using ::testing::make_tuple;
+using std::make_tuple;
#if HAVE_SSE2
#if CONFIG_VP9_HIGHBITDEPTH