blob: a0cec1478b9edf40670c813c60eeaef66d903e82 [file] [log] [blame]
Avi Drissman4e1b7bc32022-09-15 14:03:501// Copyright 2016 The Chromium Authors
guidoufc3a3ed82016-04-15 19:00:592// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "base/command_line.h"
mcasas6b8c0c82016-07-29 23:04:356#include "content/browser/webrtc/webrtc_content_browsertest_base.h"
Peter Kasting919ce652020-05-07 10:22:367#include "content/public/test/browser_test.h"
Camillo Brunidcd255e32021-10-14 15:50:058#include "third_party/blink/public/common/switches.h"
guidoufc3a3ed82016-04-15 19:00:599
10namespace {
11
12const char kJavaScriptFeaturesNeeded[] = "--expose-gc";
13const char kDataChannelHtmlFile[] = "/media/datachannel_test.html";
14
15} // namespace
16
17namespace content {
18
guidou5f5f9f2b2017-05-19 15:09:4319class WebRtcDataChannelTest : public WebRtcContentBrowserTestBase {
guidoufc3a3ed82016-04-15 19:00:5920 public:
guidou5f5f9f2b2017-05-19 15:09:4321 WebRtcDataChannelTest() {}
Peter Boström828b9022021-09-21 02:28:4322
23 WebRtcDataChannelTest(const WebRtcDataChannelTest&) = delete;
24 WebRtcDataChannelTest& operator=(const WebRtcDataChannelTest&) = delete;
25
guidou5f5f9f2b2017-05-19 15:09:4326 ~WebRtcDataChannelTest() override {}
guidoufc3a3ed82016-04-15 19:00:5927
28 void SetUpCommandLine(base::CommandLine* command_line) override {
mcasas41f5b702016-08-03 20:19:4129 WebRtcContentBrowserTestBase::SetUpCommandLine(command_line);
guidoufc3a3ed82016-04-15 19:00:5930 AppendUseFakeUIForMediaStreamFlag();
Lei Zhanga6aac9d2024-07-10 20:59:3831 command_line->AppendSwitchASCII(blink::switches::kJavaScriptFlags,
32 kJavaScriptFeaturesNeeded);
guidoufc3a3ed82016-04-15 19:00:5933 }
guidoufc3a3ed82016-04-15 19:00:5934};
35
johnme9a56aeb2017-06-19 14:04:1136// Flaky on all platforms: https://crbug.com/734567
37IN_PROC_BROWSER_TEST_F(WebRtcDataChannelTest, DISABLED_DataChannelGC) {
Chris Fredricksona7c28c82023-03-29 16:58:4438 MakeTypicalCall("testDataChannelGC();", kDataChannelHtmlFile);
guidoufc3a3ed82016-04-15 19:00:5939}
40
41} // namespace content