@@ -319,6 +319,14 @@ testSeek _ =
319
319
320
320
runTest test
321
321
322
+ testSetEcho : '{io2.IO} [Result]
323
+ testSetEcho = do
324
+ a = setEcho.impl (stdHandle StdErr) true
325
+ b = setEcho.impl (stdHandle StdErr) false
326
+ match (a, b) with
327
+ (Right _, Right _) -> [ Ok "setEcho works" ]
328
+ _ -> [ Fail "setEcho failure" ]
329
+
322
330
testAppend : '{io2.IO} [Result]
323
331
testAppend _ =
324
332
test = 'let
@@ -352,17 +360,19 @@ testAppend _ =
352
360
353
361
⍟ These new definitions are ok to `add`:
354
362
355
- testAppend : '{IO} [Result]
356
- testSeek : '{IO} [Result]
363
+ testAppend : '{IO} [Result]
364
+ testSeek : '{IO} [Result]
365
+ testSetEcho : '{IO} [Result]
357
366
```
358
367
359
368
``` ucm
360
369
scratch/main> add
361
370
362
371
⍟ I've added these definitions:
363
372
364
- testAppend : '{IO} [Result]
365
- testSeek : '{IO} [Result]
373
+ testAppend : '{IO} [Result]
374
+ testSeek : '{IO} [Result]
375
+ testSetEcho : '{IO} [Result]
366
376
367
377
scratch/main> io.test testSeek
368
378
@@ -380,6 +390,16 @@ scratch/main> io.test testSeek
380
390
381
391
Tip: Use view 1 to view the source of a test.
382
392
393
+ scratch/main> io.test testSetEcho
394
+
395
+ New test results:
396
+
397
+ 1. testSetEcho ◉ setEcho works
398
+
399
+ ✅ 1 test(s) passing
400
+
401
+ Tip: Use view 1 to view the source of a test.
402
+
383
403
scratch/main> io.test testAppend
384
404
385
405
New test results:
0 commit comments