| Index: webrtc/test/field_trial.h
|
| diff --git a/webrtc/test/field_trial.h b/webrtc/test/field_trial.h
|
| index 6503254729ac1550da7a927cca79dbf264c626fd..d448f3411d5407253a788da95d0e8938dc78fa18 100644
|
| --- a/webrtc/test/field_trial.h
|
| +++ b/webrtc/test/field_trial.h
|
| @@ -12,6 +12,7 @@
|
| #define WEBRTC_TEST_FIELD_TRIAL_H_
|
|
|
| #include <string>
|
| +#include <map>
|
|
|
| namespace webrtc {
|
| namespace test {
|
| @@ -31,6 +32,16 @@ namespace test {
|
| // passed to it. That can be used to find out if a binary is parsing the flags.
|
| void InitFieldTrialsFromString(const std::string& config);
|
|
|
| +// This class is used to override field-trial configs within specific tests.
|
| +// After this class goes out of scope previous field trials will be restored.
|
| +class ScopedFieldTrials {
|
| + public:
|
| + explicit ScopedFieldTrials(const std::string& config);
|
| + ~ScopedFieldTrials();
|
| + private:
|
| + const std::map<std::string, std::string> previous_field_trials_;
|
| +};
|
| +
|
| } // namespace test
|
| } // namespace webrtc
|
|
|
|
|