chromium/chrome/browser/vr/test/webxr_vr_browser_test.cc

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

#include "chrome/browser/vr/test/webxr_vr_browser_test.h"

#include <cstring>

#include "build/build_config.h"
#include "content/public/browser/web_contents.h"
#include "content/public/test/browser_test_utils.h"
#include "testing/gmock/include/gmock/gmock.h"

#if BUILDFLAG(ENABLE_VR)
#include "device/vr/public/cpp/features.h"
#endif

_;
Invoke;

namespace vr {

WebXrVrBrowserTestBase::WebXrVrBrowserTestBase() {}

WebXrVrBrowserTestBase::~WebXrVrBrowserTestBase() = default;

void WebXrVrBrowserTestBase::EnterSessionWithUserGesture(
    content::WebContents* web_contents) {}

void WebXrVrBrowserTestBase::EnterSessionWithUserGestureOrFail(
    content::WebContents* web_contents) {}

void WebXrVrBrowserTestBase::EndSession(content::WebContents* web_contents) {}

void WebXrVrBrowserTestBase::EndSessionOrFail(
    content::WebContents* web_contents) {}

gfx::Vector3dF WebXrVrBrowserTestBase::GetControllerOffset() const {}

permissions::PermissionRequestManager*
WebXrVrBrowserTestBase::GetPermissionRequestManager() {}

permissions::PermissionRequestManager*
WebXrVrBrowserTestBase::GetPermissionRequestManager(
    content::WebContents* web_contents) {}

WebXrVrRuntimelessBrowserTest::WebXrVrRuntimelessBrowserTest() {}

WebXrVrRuntimelessBrowserTestSensorless::
    WebXrVrRuntimelessBrowserTestSensorless() {}

#if BUILDFLAG(ENABLE_OPENXR)
WebXrVrOpenXrBrowserTestBase::WebXrVrOpenXrBrowserTestBase() {
  enable_features_.push_back(device::features::kOpenXR);
}

WebXrVrOpenXrBrowserTestBase::~WebXrVrOpenXrBrowserTestBase() = default;

XrBrowserTestBase::RuntimeType WebXrVrOpenXrBrowserTestBase::GetRuntimeType()
    const {
  return XrBrowserTestBase::RuntimeType::RUNTIME_OPENXR;
}

WebXrVrOpenXrBrowserTest::WebXrVrOpenXrBrowserTest() {
  runtime_requirements_.push_back(XrTestRequirement::DIRECTX_11_1);
}

WebXrVrOpenXrBrowserTestWebXrDisabled::WebXrVrOpenXrBrowserTestWebXrDisabled() {
  disable_features_.push_back(features::kWebXr);
}
#endif  // BUIDFLAG(ENABLE_OPENXR)

}  // namespace vr