chromium/chrome/browser/metrics/structured/test/structured_metrics_mixin.h

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef CHROME_BROWSER_METRICS_STRUCTURED_TEST_STRUCTURED_METRICS_MIXIN_H_
#define CHROME_BROWSER_METRICS_STRUCTURED_TEST_STRUCTURED_METRICS_MIXIN_H_

#include <optional>

#include "base/files/scoped_temp_dir.h"
#include "base/test/scoped_run_loop_timeout.h"
#include "base/time/time.h"
#include "chrome/test/base/mixin_based_in_process_browser_test.h"
#include "components/metrics/metrics_provider.h"
#include "components/metrics/structured/structured_metrics_recorder.h"
#include "components/metrics/structured/test/test_event_storage.h"
#include "third_party/metrics_proto/structured_data.pb.h"

// Mixin browser tests can use StructuredMetricsMixin to set up test
// environment for structured metrics recording.
//
// To use the mixin, create it as a member variable in your test, e.g.:
//
//   class MyTest : public MixinBasedInProcessBrowserTest {
//    private:
//     StructuredMetricsMixin structured_metrics_mixin_{&mixin_host_};
namespace metrics::structured {

class StructuredMetricsService;

class StructuredMetricsMixin : public InProcessBrowserTestMixin {};

}  // namespace metrics::structured

#endif  // CHROME_BROWSER_METRICS_STRUCTURED_TEST_STRUCTURED_METRICS_MIXIN_H_