History

change the /sdcard/ and also alignment format

syureyi committed 12 years ago

Commit 43351671 parent b53f8905 files · +40 −122Browse files

Showing the changes to test/api/decoder_test.cpp (1 of 5 files). Show all

Unified · Split

test/api/decoder_test.cpp+6−38
@@ -1,6 +1,7 @@
11 #include <gtest/gtest.h>
22 #include "utils/HashFunctions.h"
33 #include "BaseDecoderTest.h"
4+#include <string>
45
56 static void UpdateHashFromPlane (SHA1Context* ctx, const uint8_t* plane,
67 int width, int height, int stride) {
@@ -52,7 +53,12 @@ class DecoderOutputTest : public ::testing::WithParamInterface<FileParam>, · 45 unmodified lines
5253
5354 TEST_P (DecoderOutputTest, CompareOutput) {
5455 FileParam p = GetParam();
56+#if defined(ANDROID_NDK)
57+ std::string filename = std::string ("/sdcard/") + p.fileName;
58+ DecodeFile (filename.c_str(), this);
59+#else
5560 DecodeFile (p.fileName, this);
61+#endif
5662
5763 unsigned char digest[SHA_DIGEST_LENGTH];
5864 SHA1Result (&ctx_, digest);
@@ -60,43 +66,6 @@ TEST_P (DecoderOutputTest, CompareOutput) { · 1 unmodified line
6066 CompareHash (digest, p.hashStr);
6167 }
6268 }
63−#if defined(ANDROID_NDK)
64−
65−static const FileParam kFileParamArray[] = {
66− {"/sdcard/res/test_vd_1d.264", "5827d2338b79ff82cd091c707823e466197281d3"},
67− {"/sdcard/res/test_vd_rc.264", "eea02e97bfec89d0418593a8abaaf55d02eaa1ca"},
68− {"/sdcard/res/Static.264", "91dd4a7a796805b2cd015cae8fd630d96c663f42"},
69− {"/sdcard/res/BA1_FT_C.264", "418d152fb85709b6f172799dcb239038df437cfa"},
70− {"/sdcard/res/BA1_Sony_D.jsv", "d94b5ceed5686a03ea682b53d415dee999d27eb6"},
71− {"/sdcard/res/BAMQ1_JVC_C.264", "613cf662c23e5d9e1d7da7fe880a3c427411d171"},
72− {"/sdcard/res/BAMQ2_JVC_C.264", "11bcf3713f520e606a8326d37e00e5fd6c9fd4a0"},
73− {"/sdcard/res/BA_MW_D.264", "afd7a9765961ca241bb4bdf344b31397bec7465a"},
74− {"/sdcard/res/BANM_MW_D.264", "92d924a857a1a7d7d9b224eaa3887830f15dee7f"},
75− {"/sdcard/res/BASQP1_Sony_C.jsv", "3986c8c9d2876d2f0748b925101b152c6ec8b811"},
76− {"/sdcard/res/CI1_FT_B.264", "cbfec15e17a504678b19a1191992131c92a1ac26"},
77− {"/sdcard/res/CI_MW_D.264", "289f29a103c8d95adf2909c646466904be8b06d7"},
78− {"/sdcard/res/CVFC1_Sony_C.jsv", "4641abd7419a5580b97f16e83fd1d566339229d0"},
79− {"/sdcard/res/CVPCMNL1_SVA_C.264", "c2b0d964de727c64b9fccb58f63b567c82bda95a"},
80− {"/sdcard/res/LS_SVA_D.264", "72118f4d1674cf14e58bed7e67cb3aeed3df62b9"},
81− {"/sdcard/res/MIDR_MW_D.264", "9467030f4786f75644bf06a7fc809c36d1959827"},
82− {"/sdcard/res/MPS_MW_A.264", "67f1cfbef0e8025ed60dedccf8d9558d0636be5f"},
83− {"/sdcard/res/MR1_BT_A.h264", "6e585f8359667a16b03e5f49a06f5ceae8d991e0"},
84− {"/sdcard/res/MR1_MW_A.264", "d9e2bf34e9314dcc171ddaea2c5015d0421479f2"},
85− {"/sdcard/res/MR2_MW_A.264", "628b1d4eff04c2d277f7144e23484957dad63cbe"},
86− {"/sdcard/res/MR2_TANDBERG_E.264", "74d618bc7d9d41998edf4c85d51aa06111db6609"},
87− {"/sdcard/res/NL1_Sony_D.jsv", "e401e30669938443c2f02522fd4d5aa1382931a0"},
88− {"/sdcard/res/NLMQ1_JVC_C.264", "f3265c6ddf8db1b2bf604d8a2954f75532e28cda"},
89− {"/sdcard/res/NLMQ2_JVC_C.264", "350ae86ef9ba09390d63a09b7f9ff54184109ca8"},
90− {"/sdcard/res/NRF_MW_E.264", "20732198c04cd2591350a361e4510892f6eed3f0"},
91− {"/sdcard/res/SVA_BA1_B.264", "c4543b24823b16c424c673616c36c7f537089b2d"},
92− {"/sdcard/res/SVA_BA2_D.264", "98ff2d67860462d8d8bcc9352097c06cc401d97e"},
93− {"/sdcard/res/SVA_Base_B.264", "91f514d81cd33de9f6fbf5dbefdb189cc2e7ecf4"},
94− {"/sdcard/res/SVA_CL1_E.264", "4fe09ab6cdc965ea10a20f1d6dd38aca954412bb"},
95− {"/sdcard/res/SVA_FM1_E.264", "fad08c4ff7cf2307b6579853d0f4652fc26645d3"},
96− {"/sdcard/res/SVA_NL1_B.264", "6d63f72a0c0d833b1db0ba438afff3b4180fb3e6"},
97− {"/sdcard/res/SVA_NL2_E.264", "70453ef8097c94dd190d6d2d1d5cb83c67e66238"}
98−};
99−#else
10069 static const FileParam kFileParamArray[] = {
10170 {"res/test_vd_1d.264", "5827d2338b79ff82cd091c707823e466197281d3"},
10271 {"res/test_vd_rc.264", "eea02e97bfec89d0418593a8abaaf55d02eaa1ca"},
@@ -132,6 +101,5 @@ static const FileParam kFileParamArray[] = { · 29 unmodified lines
132101 {"res/SVA_NL2_E.264", "70453ef8097c94dd190d6d2d1d5cb83c67e66238"}
133102 };
134103
135−#endif
136104 INSTANTIATE_TEST_CASE_P (DecodeFile, DecoderOutputTest,
137105 ::testing::ValuesIn (kFileParamArray));

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t