Blame view

bower_components/prism/tests/languages/puppet/string_feature.test 584 Bytes
f748e9cf   Luigi Serra   new controllet an...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
  ''

  'fo\'obar'

  'foo

  $bar

  baz'

  ""

  "fo\"obar"

  "foo

  $bar

  baz"

  

  ----------------------------------------------------

  

  [

  	["string", ["''"]],

  	["string", ["'fo\\'obar'"]],

  	["string", ["'foo\r\n$bar\r\nbaz'"]],

  	["string", [["double-quoted", ["\"\""]]]],

  	["string", [["double-quoted", ["\"fo\\\"obar\""]]]],

  	["string", [["double-quoted", [

  		"\"foo\r\n",

  		["interpolation", ["$bar"]],

  		"\r\nbaz\""

  	]]]]

  ]

  

  ----------------------------------------------------

  

  Checks for strings.

  Also checks that string interpolation only applies to double-quoted strings.