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

Unified Diff: lib/src/prism/tests/languages/jade/multiline-script_feature.test

Issue 1418513006: update elements and fix some bugs (Closed) Base URL: git@github.com:dart-lang/polymer_elements.git@master
Patch Set: code review updates Created 5 years, 2 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: lib/src/prism/tests/languages/jade/multiline-script_feature.test
diff --git a/lib/src/prism/tests/languages/jade/multiline-script_feature.test b/lib/src/prism/tests/languages/jade/multiline-script_feature.test
new file mode 100644
index 0000000000000000000000000000000000000000..5648bf3d6cfbd24275c74e6f4fac7d61a423214e
--- /dev/null
+++ b/lib/src/prism/tests/languages/jade/multiline-script_feature.test
@@ -0,0 +1,58 @@
+script.
+ alert(42);
+
+.
+ script(type='text/javascript').
+
+ if(foo) {
+ bar(1 + 5);
+ }
+
+----------------------------------------------------
+
+[
+ ["tag", [
+ "script"
+ ]],
+ ["punctuation", "."],
+ ["multiline-script", [
+ ["function", "alert"],
+ ["punctuation", "("],
+ ["number", "42"],
+ ["punctuation", ")"],
+ ["punctuation", ";"]
+ ]],
+
+ ["punctuation", "."],
+
+ ["tag", [
+ "script",
+ ["attributes", [
+ ["punctuation", "("],
+ ["attr-name", "type"],
+ ["punctuation", "="],
+ ["attr-value", [["string", "'text/javascript'"]]],
+ ["punctuation", ")"]
+ ]]
+ ]],
+ ["punctuation", "."],
+ ["multiline-script", [
+ ["keyword", "if"],
+ ["punctuation", "("],
+ "foo",
+ ["punctuation", ")"],
+ ["punctuation", "{"],
+ ["function", "bar"],
+ ["punctuation", "("],
+ ["number", "1"],
+ ["operator", "+"],
+ ["number", "5"],
+ ["punctuation", ")"],
+ ["punctuation", ";"],
+ ["punctuation", "}"]
+ ]]
+]
+
+----------------------------------------------------
+
+Checks for multi-line scripts. The alone dot serves as a separator.

Powered by Google App Engine
This is Rietveld 408576698