Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2539)

Unified Diff: chrome/browser/media/encrypted_media_browsertest.cc

Issue 2426813002: EME: Close existing sessions on CDM failure (Closed)
Patch Set: rename result (+rebase) Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/renderer/pepper/content_decryptor_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/media/encrypted_media_browsertest.cc
diff --git a/chrome/browser/media/encrypted_media_browsertest.cc b/chrome/browser/media/encrypted_media_browsertest.cc
index 93d4710081fcce1db9cb497eeeb51d83b39b2bc4..e76f0d8c342d5e70d3d22dd6668d0576d30e5793 100644
--- a/chrome/browser/media/encrypted_media_browsertest.cc
+++ b/chrome/browser/media/encrypted_media_browsertest.cc
@@ -83,6 +83,7 @@ const char kEmeUpdateFailed[] = "EME_UPDATE_FAILED";
const char kEmeErrorEvent[] = "EME_ERROR_EVENT";
const char kEmeMessageUnexpectedType[] = "EME_MESSAGE_UNEXPECTED_TYPE";
const char kEmeRenewalMissingHeader[] = "EME_RENEWAL_MISSING_HEADER";
+const char kEmeSessionClosedAndError[] = "EME_SESSION_CLOSED_AND_ERROR";
const char kDefaultEmePlayer[] = "eme_player.html";
@@ -610,20 +611,20 @@ IN_PROC_BROWSER_TEST_F(ECKEncryptedMediaTest, InitializeCDMFail) {
kEmeNotSupportedError);
}
-// When CDM crashes, we should still get a decode error. |kError| is reported
-// when the HTMLVideoElement error event fires, indicating an error happened
-// during playback.
+// When CDM crashes, we should still get a decode error and all sessions should
+// be closed.
IN_PROC_BROWSER_TEST_F(ECKEncryptedMediaTest, CDMCrashDuringDecode) {
IgnorePluginCrash();
- TestNonPlaybackCases(kExternalClearKeyCrashKeySystem, kError);
+ TestNonPlaybackCases(kExternalClearKeyCrashKeySystem,
+ kEmeSessionClosedAndError);
}
// Testing that the media browser test does fail on plugin crash.
IN_PROC_BROWSER_TEST_F(ECKEncryptedMediaTest, CDMExpectedCrash) {
// Plugin crash is not ignored by default, the test is expected to fail.
- EXPECT_NONFATAL_FAILURE(
- TestNonPlaybackCases(kExternalClearKeyCrashKeySystem, kError),
- "Failing test due to plugin crash.");
+ EXPECT_NONFATAL_FAILURE(TestNonPlaybackCases(kExternalClearKeyCrashKeySystem,
+ kEmeSessionClosedAndError),
+ "Failing test due to plugin crash.");
}
IN_PROC_BROWSER_TEST_F(ECKEncryptedMediaTest, FileIOTest) {
« no previous file with comments | « no previous file | content/renderer/pepper/content_decryptor_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698