Parcourir la source

Tests/LibWeb: Initialize Blob with string and read it from text()

Kenneth Myhra il y a 1 an
Parent
commit
b72489409a

+ 1 - 0
Tests/LibWeb/Text/expected/FileAPI/Blob-intialized-with-strings-read-from-text.txt

@@ -0,0 +1 @@
+PASS

+ 12 - 0
Tests/LibWeb/Text/input/FileAPI/Blob-intialized-with-strings-read-from-text.html

@@ -0,0 +1,12 @@
+<script src="../include.js"></script>
+<script>
+    asyncTest(async (done) => {
+        const blob = new Blob(["This is some data to be read! 🦬"]);
+        const text = await blob.text();
+        if (text === "This is some data to be read! 🦬")
+            println("PASS");
+        else
+            println("FAIL");
+        done();
+    });
+</script>