From 03443412d7038a8a68da1137ea7e6b38fdbc728c Mon Sep 17 00:00:00 2001 From: Christian Schneider Date: Mon, 28 Jul 2008 15:20:54 +0000 Subject: Quote identifier if it is a javascript reserved word --- tests/itjs.t | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/itjs.t') diff --git a/tests/itjs.t b/tests/itjs.t index 4b4b0c8..ef3437a 100755 --- a/tests/itjs.t +++ b/tests/itjs.t @@ -41,4 +41,10 @@ is( 'nested arrays' ); +is( + itjs::serialize(array('import' => array('function' => array(true, 42)))), + '{\'import\':{\'function\':[true, 42]}}', + 'keywords' +); + ?> -- cgit v1.2.3