about summary refs log tree commit diff stats
path: root/sandbox
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2017-06-09 11:29:15 -0700
committerKartik K. Agaram <vc@akkartik.com>2017-06-09 11:29:15 -0700
commit6d12a8c4ebe25527c92a934702e2628ce8c4bd4c (patch)
tree051825d9664a06fc3bc7085031fe62dfeb94c417 /sandbox
parentf53746f80145a184b5e4a6974175e2f92f49dcba (diff)
downloadmu-6d12a8c4ebe25527c92a934702e2628ce8c4bd4c.tar.gz
3902 - drop redundant redraw of recipe side on F4
This change is interesting because I only updated one test to gain confidence
that F4 will never redraw the recipe side. (Most of the changes are to
explicitly render-all before each scenario.)
Diffstat (limited to 'sandbox')
-rw-r--r--sandbox/004-programming-environment.mu1
-rw-r--r--sandbox/005-sandbox.mu3
-rw-r--r--sandbox/006-sandbox-copy.mu3
-rw-r--r--sandbox/007-sandbox-delete.mu1
-rw-r--r--sandbox/008-sandbox-edit.mu3
-rw-r--r--sandbox/009-sandbox-test.mu1
-rw-r--r--sandbox/010-sandbox-trace.mu3
-rw-r--r--sandbox/011-errors.mu14
8 files changed, 29 insertions, 0 deletions
diff --git a/sandbox/004-programming-environment.mu b/sandbox/004-programming-environment.mu
index b260a110..9e28a215 100644
--- a/sandbox/004-programming-environment.mu
+++ b/sandbox/004-programming-environment.mu
@@ -249,6 +249,7 @@ scenario backspace-over-text [
   ]
   # sandbox editor contains an instruction without storing outputs
   env:&:environment <- new-programming-environment resources, screen, []
+  render-all screen, env, render
   # run the code in the editors
   assume-console [
     type [a]
diff --git a/sandbox/005-sandbox.mu b/sandbox/005-sandbox.mu
index b0b28ead..3375a60f 100644
--- a/sandbox/005-sandbox.mu
+++ b/sandbox/005-sandbox.mu
@@ -47,6 +47,7 @@ scenario run-and-show-results [
   ]
   # sandbox editor contains an instruction without storing outputs
   env:&:environment <- new-programming-environment resources, screen, [divide-with-remainder 11, 3]
+  render-all screen, env, render
   # run the code in the editors
   assume-console [
     press F4
@@ -521,6 +522,7 @@ scenario run-updates-results [
   ]
   # sandbox editor contains an instruction without storing outputs
   env:&:environment <- new-programming-environment resources, screen, [foo]  # contents of sandbox editor
+  render-all screen, env, render
   # run the code in the editors
   assume-console [
     press F4
@@ -575,6 +577,7 @@ scenario run-instruction-manages-screen-per-sandbox [
   ]
   # sandbox editor contains an instruction
   env:&:environment <- new-programming-environment resources, screen, [print screen, 4]  # contents of sandbox editor
+  render-all screen, env, render
   # run the code in the editor
   assume-console [
     press F4
diff --git a/sandbox/006-sandbox-copy.mu b/sandbox/006-sandbox-copy.mu
index 4835f02e..33e31cc9 100644
--- a/sandbox/006-sandbox-copy.mu
+++ b/sandbox/006-sandbox-copy.mu
@@ -9,6 +9,7 @@ scenario copy-a-sandbox-to-editor [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [add 1, 1]  # contents of sandbox editor
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
@@ -75,6 +76,7 @@ scenario copy-a-sandbox-to-editor-2 [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [add 1, 1]  # contents of sandbox editor
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
@@ -228,6 +230,7 @@ scenario copy-fails-if-sandbox-editor-not-empty [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [add 1, 1]  # contents of sandbox editor
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
diff --git a/sandbox/007-sandbox-delete.mu b/sandbox/007-sandbox-delete.mu
index 107c861c..955eac8f 100644
--- a/sandbox/007-sandbox-delete.mu
+++ b/sandbox/007-sandbox-delete.mu
@@ -7,6 +7,7 @@ scenario deleting-sandboxes [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, []
+  render-all screen, env, render
   # run a few commands
   assume-console [
     type [divide-with-remainder 11, 3]
diff --git a/sandbox/008-sandbox-edit.mu b/sandbox/008-sandbox-edit.mu
index ec4fd578..aef61619 100644
--- a/sandbox/008-sandbox-edit.mu
+++ b/sandbox/008-sandbox-edit.mu
@@ -8,6 +8,7 @@ scenario clicking-on-sandbox-edit-button-moves-it-to-editor [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [add 2, 2]
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
@@ -60,6 +61,7 @@ scenario clicking-on-sandbox-edit-button-moves-it-to-editor-2 [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [add 2, 2]
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
@@ -162,6 +164,7 @@ scenario sandbox-with-print-can-be-edited [
   ]
   # right editor contains a print instruction
   env:&:environment <- new-programming-environment resources, screen, [print screen, 4]
+  render-all screen, env, render
   # run the sandbox
   assume-console [
     press F4
diff --git a/sandbox/009-sandbox-test.mu b/sandbox/009-sandbox-test.mu
index 1c24bcb8..34fed44e 100644
--- a/sandbox/009-sandbox-test.mu
+++ b/sandbox/009-sandbox-test.mu
@@ -13,6 +13,7 @@ scenario sandbox-click-on-result-toggles-color-to-green [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   # run it
   assume-console [
     press F4
diff --git a/sandbox/010-sandbox-trace.mu b/sandbox/010-sandbox-trace.mu
index 27f2915a..2c4e40cc 100644
--- a/sandbox/010-sandbox-trace.mu
+++ b/sandbox/010-sandbox-trace.mu
@@ -8,6 +8,7 @@ scenario sandbox-click-on-code-toggles-app-trace [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [stash [abc]]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -77,6 +78,7 @@ scenario sandbox-shows-app-trace-and-result [
   test-sandbox:text <- new [stash [abc]
 add 2, 2]
   env:&:environment <- new-programming-environment resources, screen, test-sandbox
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -121,6 +123,7 @@ scenario clicking-on-app-trace-does-nothing [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [stash 123456789]
+  render-all screen, env, render
   # create and expand the trace
   assume-console [
     press F4
diff --git a/sandbox/011-errors.mu b/sandbox/011-errors.mu
index 7c04621d..06a5fb16 100644
--- a/sandbox/011-errors.mu
+++ b/sandbox/011-errors.mu
@@ -163,6 +163,7 @@ scenario run-updates-status-with-first-erroneous-sandbox [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, []
+  render-all screen, env, render
   assume-console [
     # create invalid sandbox 1
     type [get foo, x:offset]
@@ -187,6 +188,7 @@ scenario run-updates-status-with-first-erroneous-sandbox-2 [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, []
+  render-all screen, env, render
   assume-console [
     # create invalid sandbox 2
     type [get foo, x:offset]
@@ -214,6 +216,7 @@ scenario run-hides-errors-from-past-sandboxes [
   assume-resources [
   ]
   env:&:environment <- new-programming-environment resources, screen, [get foo, x:offset]  # invalid
+  render-all screen, env, render
   assume-console [
     press F4  # generate error
   ]
@@ -256,6 +259,7 @@ scenario run-updates-errors-for-shape-shifting-recipes [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo 2]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -307,6 +311,7 @@ scenario run-avoids-spurious-errors-on-reloading-shape-shifting-recipes [
   test-sandbox:text <- new [x:&:list:num <- copy 0
 to-text x]
   env:&:environment <- new-programming-environment resources, screen, test-sandbox
+  render-all screen, env, render
   # run it once
   assume-console [
     press F4
@@ -357,6 +362,7 @@ scenario run-shows-missing-type-errors [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -385,6 +391,7 @@ scenario run-shows-unbalanced-bracket-errors [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -418,6 +425,7 @@ scenario run-shows-get-on-non-container-errors [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -450,6 +458,7 @@ scenario run-shows-non-literal-get-argument-errors [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -481,6 +490,7 @@ scenario run-shows-errors-everytime [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -520,6 +530,7 @@ scenario run-instruction-and-print-errors [
   ]
   # editor contains an illegal instruction
   env:&:environment <- new-programming-environment resources, screen, [get 1:&:point, 1:offset]
+  render-all screen, env, render
   assume-console [
     press F4
   ]
@@ -559,6 +570,7 @@ scenario run-instruction-and-print-errors-only-once [
   ]
   # editor contains an illegal instruction
   env:&:environment <- new-programming-environment resources, screen, [get 1234:num, foo:offset]
+  render-all screen, env, render
   # run the code in the editors multiple times
   assume-console [
     press F4
@@ -593,6 +605,7 @@ scenario sandbox-can-handle-infinite-loop [
 loop
 }]
   env:&:environment <- new-programming-environment resources, screen, test-sandbox
+  render-all screen, env, render
   # run the sandbox
   assume-console [
     press F4
@@ -632,6 +645,7 @@ scenario sandbox-with-errors-shows-trace [
     ]
   ]
   env:&:environment <- new-programming-environment resources, screen, [foo 4, 0]
+  render-all screen, env, render
   # run
   assume-console [
     press F4