| Index: chrome/browser/media/webrtc_browsertest_base.h
|
| diff --git a/chrome/browser/media/webrtc_browsertest_base.h b/chrome/browser/media/webrtc_browsertest_base.h
|
| index 9cc092923d70bd74b74c590b11c1e4726562f9c6..d1f8659e168c26f41aa02147dab950d7dddb77ff 100644
|
| --- a/chrome/browser/media/webrtc_browsertest_base.h
|
| +++ b/chrome/browser/media/webrtc_browsertest_base.h
|
| @@ -38,6 +38,12 @@ class WebRtcTestBase : public InProcessBrowserTest {
|
| static const char kFailedWithPermissionDeniedError[];
|
| static const char kFailedWithPermissionDismissedError[];
|
|
|
| + enum ExpectedPromptBehaviour {
|
| + IGNORE_PROMPT_BEHAVIOUR,
|
| + EXPECT_PROMPT_SHOWN,
|
| + EXPECT_PROMPT_NOT_SHOWN
|
| + };
|
| +
|
| protected:
|
| WebRtcTestBase();
|
| ~WebRtcTestBase() override;
|
| @@ -46,17 +52,25 @@ class WebRtcTestBase : public InProcessBrowserTest {
|
| // chrome/test/data/webrtc/getusermedia.js.
|
| // If an error is reported back from the getUserMedia call, these functions
|
| // will return false.
|
| - bool GetUserMediaAndAccept(content::WebContents* tab_contents) const;
|
| + bool GetUserMediaAndAccept(
|
| + content::WebContents* tab_contents,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour) const;
|
| bool GetUserMediaWithSpecificConstraintsAndAccept(
|
| content::WebContents* tab_contents,
|
| - const std::string& constraints) const;
|
| - void GetUserMediaAndDeny(content::WebContents* tab_contents);
|
| + const std::string& constraints,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour) const;
|
| + void GetUserMediaAndDeny(content::WebContents* tab_contents,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour);
|
| void GetUserMediaWithSpecificConstraintsAndDeny(
|
| content::WebContents* tab_contents,
|
| - const std::string& constraints) const;
|
| - void GetUserMediaAndDismiss(content::WebContents* tab_contents) const;
|
| + const std::string& constraints,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour) const;
|
| + void GetUserMediaAndDismiss(
|
| + content::WebContents* tab_contents,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour) const;
|
| void GetUserMedia(content::WebContents* tab_contents,
|
| - const std::string& constraints) const;
|
| + const std::string& constraints,
|
| + ExpectedPromptBehaviour expected_prompt_behaviour) const;
|
|
|
| // Convenience method which opens the page at url, calls GetUserMediaAndAccept
|
| // and returns the new tab.
|
|
|