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

Unified Diff: LayoutTests/http/tests/webfont/webfont-cors.html

Issue 316353003: Remove font fetching fallback for CORS failures (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add/Update tests Created 6 years, 6 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/http/tests/webfont/webfont-cors.html
diff --git a/LayoutTests/http/tests/webfont/webfont-cors.html b/LayoutTests/http/tests/webfont/webfont-cors.html
new file mode 100644
index 0000000000000000000000000000000000000000..b2b85d5f8330afd51999b7f72e71575f28579cc5
--- /dev/null
+++ b/LayoutTests/http/tests/webfont/webfont-cors.html
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<style>
+@font-face {
+ font-family: corsOK;
+ src: url(http://127.0.0.1:8080/css/resources/cors-ahem.php);
+}
+@font-face {
+ font-family: corsNG;
+ src: url(http://127.0.0.1:8080/resources/Ahem.ttf);
+}
+</style>
+<div style="font-family: corsOK;">
+This text should be rendered with ahem font.
+</div>
+<div style="font-family: corsNG;">
+This text should NOT be rendered with ahem font.
+</div>
+<script>
+if (window.testRunner)
+ testRunner.waitUntilDone();
+
+document.fonts.ready().then(function() {
+ if (window.testRunner)
+ testRunner.notifyDone();
+});
+</script>

Powered by Google App Engine
This is Rietveld 408576698