Renamed src/lib Parenscript library files, got rid of Parenscript CSS system.
[clinton/parenscript.git] / t / reference-tests.lisp
index 4aea054..a90792e 100644 (file)
@@ -354,10 +354,10 @@ _js2.style.left = _js1;")
 
 (test-ps-js variable-declaration-2
   (if (= i 1)
-    (progn (defvar blorg "hallo")
-           (alert blorg))
-    (progn (defvar blorg "blitzel")
-           (alert blorg)))
+    (let* ((blorg "hallo"))
+      (alert blorg))
+    (let* ((blorg "blitzel"))
+      (alert blorg)))
   "if (i == 1) {
   var blorg = 'hallo';
   alert(blorg);
@@ -368,16 +368,26 @@ _js2.style.left = _js1;")
 
 (test-ps-js variable-declaration-3
   (if (= i 1)
-    (let ((blorg "hallo"))
+    (lexical-let* ((blorg "hallo"))
       (alert blorg))
-    (let ((blorg "blitzel"))
+    (lexical-let* ((blorg "blitzel"))
       (alert blorg)))
   "if (i == 1) {
-  var blorg = 'hallo';
-  alert(blorg);
+    (function () {
+        var newlexicalcontext1 = new Object;
+        newlexicalcontext1['blorg'] = 'hallo';
+        with (newlexicalcontext1) {
+            alert(blorg);
+        };
+     })();
 } else {
-  var blorg = 'blitzel';
-  alert(blorg);
+    (function () {
+        var newlexicalcontext3 = new Object;
+        newlexicalcontext3['blorg'] = 'blitzel';
+        with (newlexicalcontext3) {
+            alert(blorg);
+        };
+    })();
 }")
 
 (test-ps-js iteration-constructs-1
@@ -487,7 +497,7 @@ _js2.style.left = _js1;")
   "document.write('<a href=\"#\" onclick=\"' + 'javascript:transport()' + '\">link</a>')")
 
 (test-ps-js the-html-generator-4
-  (let ((disabled nil)
+  (let* ((disabled nil)
       (authorized t))
    (setf element.inner-h-t-m-l
          (ps-html ((:textarea (or disabled (not authorized)) :disabled "disabled")
@@ -499,17 +509,3 @@ _js2.style.left = _js1;")
    + (disabled || !authorized ? ' disabled=\"' + 'disabled' + '\"' : '')
    + '>Edit me</textarea>';")
 
-(test-ps-js the-html-generator-5
-  (css-inline :color "red"
-            :font-size "x-small")
-  "'color:red;font-size:x-small'")
-
-(test-ps-js the-html-generator-6
-  (defun make-color-div(color-name)
-    (return (ps-html ((:div :style (css-inline :color color-name))
-                   color-name " looks like this."))))
-  "function makeColorDiv(colorName) {
-  return '<div style=\"' + ('color:' + colorName) + '\">' + colorName
-    + ' looks like this.</div>';
-}")
-