Beispiel #1
0
 def testJsArrayN_2(self):
     actual = html.js_array([["string1", "string2", "string3"],
                             ["string4", "string5", "string6"]],
                            N=3)
     expected = '"string1:string2:string3",\n"string4:string5:string6"'
     self.assertEqual(actual, expected)
Beispiel #2
0
 def testJsArrayMultiple(self):
     actual = html.js_array([["string1", "string2"], ["string3",
                                                      "string4"]])
     expected = '"string1:string2",\n"string3:string4"'
     self.assertEqual(actual, expected)
Beispiel #3
0
 def testJsArrayN(self):
     actual = html.js_array(
         [["string1", "string2", "string3", "string4", "string5"]], N=5)
     expected = '"string1:string2:string3:string4:string5"'
     self.assertEqual(actual, expected)
Beispiel #4
0
 def testJsArrayOverfull(self):
     actual = html.js_array([["string1", "string2", "string3"]])
     expected = '"string1:string2"'
     self.assertEqual(actual, expected)