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

Unified Diff: third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html

Issue 2675763005: Use testharness.js instead of js-test.js in LayoutTests/fast/canvas tests. (Closed)
Patch Set: Addressing comments Created 3 years, 10 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: third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html b/third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html
index f23a5386bdb4eed9113967f5eeb84bfa48fe9e96..b3065a0d6b90d3b1511a851f216912f4d96f6e51 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html
+++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-context-attributes-default-value.html
@@ -1,9 +1,6 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script src="../../resources/js-test.js"></script>
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
<script>
-
var trueAttributes = {
alpha : true,
};
@@ -31,26 +28,20 @@
window.actualContextAttributes = context.getContextAttributes();
for (key in expectedAttributes)
- shouldBe("actualContextAttributes." + key,
- expectedAttributes[key].toString());
+ assert_equals(eval("actualContextAttributes." + key),
+ expectedAttributes[key]);
}
-</script>
-</head>
-<body>
-<script>
-
- debug("Testing default value:");
- testAttributes(trueAttributes);
- debug("")
-
- debug("Testing undefined value:");
- testAttributes(trueAttributes, undefined);
- debug("")
+ test(function(t) {
+ testAttributes(trueAttributes);
+ }, 'Test default value');
- debug("Testing null value:");
- testAttributes(falseAttributes, null);
- debug("")
+ test(function(t) {
+ testAttributes(trueAttributes, undefined);
+ }, 'Test undfined value');
+ test(function(t) {
+ testAttributes(falseAttributes, null);
+ }, 'Test null value');
</script>
</body>

Powered by Google App Engine
This is Rietveld 408576698