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

Unified Diff: LayoutTests/fast/canvas/webgl/webgl-error-response.html

Issue 826363002: Webgl Info should have vendorid and deviceid of gpu. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add period at end of string. Created 5 years, 11 months 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
Index: LayoutTests/fast/canvas/webgl/webgl-error-response.html
diff --git a/LayoutTests/fast/canvas/webgl/webgl-error-response.html b/LayoutTests/fast/canvas/webgl/webgl-error-response.html
index 79410177a2839e113a8a457263139f4fc74feb07..2f042b686c917865a2fb97c2e79939c38a1d2e14 100644
--- a/LayoutTests/fast/canvas/webgl/webgl-error-response.html
+++ b/LayoutTests/fast/canvas/webgl/webgl-error-response.html
@@ -21,19 +21,26 @@ function initTest() {
}
function onContextCreationError(e) {
+ var vendoridStr = "VendorId = ";
+ var deviceidStr = "DeviceId = ";
var vendorInfoStr = "VendorInfo = ";
var renderInfoStr = "RendererInfo = ";
var driverInfoStr = "DriverInfo = ";
- var stringIndex = e.statusMessage.search(vendorInfoStr) + vendorInfoStr.length;
+ var stringIndex = e.statusMessage.search(vendoridStr) + vendoridStr.length;
+ var vendoridInfo = e.statusMessage.substring(stringIndex, e.statusMessage.search(deviceidStr) - 2);
Ken Russell (switch to Gerrit) 2015/01/15 19:30:39 All of these string searches are quite complex and
sivag 2015/01/29 05:49:36 Done.
+ stringIndex = e.statusMessage.search(deviceidStr) + deviceidStr.length;
+ var deviceidInfo = e.statusMessage.substring(stringIndex, e.statusMessage.search(vendorInfoStr) - 2);
+ stringIndex = e.statusMessage.search(vendorInfoStr) + vendorInfoStr.length;
var vendorInfo = e.statusMessage.substring(stringIndex, e.statusMessage.search(renderInfoStr) - 2);
stringIndex = e.statusMessage.search(renderInfoStr) + renderInfoStr.length;
var rendererInfo = e.statusMessage.substring(stringIndex, e.statusMessage.search(driverInfoStr) - 2 );
stringIndex = e.statusMessage.search(driverInfoStr) + driverInfoStr.length;
var driverInfo = e.statusMessage.substring(stringIndex, e.statusMessage.length - 1);
if((e.statusMessage.search("GPUInfoCollectionFailure") != -1) ||
- vendorInfo.length > 0 ||
- rendererInfo.length > 0 ||
- driverInfo.length > 0)
+ (vendoridInfo.length > 0 &&
+ deviceidInfo.length > 0 &&
+ rendererInfo.length > 0 &&
+ driverInfo.length > 0 ))
testPassed("Status message displayed for webglcontextcreationerror");
else
testFailed("Context creation error test failed");
« no previous file with comments | « no previous file | Source/core/html/canvas/WebGLRenderingContext.cpp » ('j') | Source/core/html/canvas/WebGLRenderingContext.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698