#include "ui/base/clipboard/clipboard.h"
#include <memory>
#include "base/run_loop.h"
#include "base/strings/stringprintf.h"
#include "base/test/test_future.h"
#include "chrome/browser/enterprise/data_controls/desktop_data_controls_dialog.h"
#include "chrome/browser/enterprise/data_controls/desktop_data_controls_dialog_test_helper.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/views/frame/browser_view.h"
#include "chrome/test/base/in_process_browser_test.h"
#include "chrome/test/base/ui_test_utils.h"
#include "components/enterprise/data_controls/core/browser/features.h"
#include "components/enterprise/data_controls/core/browser/test_utils.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/permissions_test_utils.h"
#include "net/dns/mock_host_resolver.h"
#include "ui/base/clipboard/scoped_clipboard_writer.h"
#include "ui/base/clipboard/test/test_clipboard.h"
#include "ui/base/data_transfer_policy/data_transfer_endpoint.h"
#include "ui/views/test/widget_activation_waiter.h"
namespace enterprise_data_protection {
namespace {
class DataProtectionClipboardBrowserTest : public InProcessBrowserTest { … };
}
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
CopyBlockedByDataControls) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
CopyWarnedByDataControls_Cancel) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
CopyWarnedByDataControls_Bypass) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
CopyAllowedByDataControls) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
PasteBlockedByDataControls) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
PasteWarnedByDataControls_Cancel) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
PasteWarnedByDataControls_Bypass) { … }
IN_PROC_BROWSER_TEST_F(DataProtectionClipboardBrowserTest,
PasteAllowedByDataControls) { … }
}