From 319f645dfcc1b897cb57f76f4219eaa3822d8233 Mon Sep 17 00:00:00 2001 From: pfdietz <pfdietz@localhost> Date: Sat, 22 Mar 2003 17:50:32 +0000 Subject: [PATCH] Beginning of tests for RESTART-BIND. --- ansi-tests/load-conditions.lsp | 2 ++ ansi-tests/restart-bind.lsp | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 ansi-tests/restart-bind.lsp diff --git a/ansi-tests/load-conditions.lsp b/ansi-tests/load-conditions.lsp index 43c8048f..05b03fa6 100644 --- a/ansi-tests/load-conditions.lsp +++ b/ansi-tests/load-conditions.lsp @@ -12,5 +12,7 @@ (load "ignore-errors.lsp") (compile-and-load "define-condition-aux.lsp") (load "define-condition.lsp") +(load "restart-bind.lsp") + diff --git a/ansi-tests/restart-bind.lsp b/ansi-tests/restart-bind.lsp new file mode 100644 index 00000000..bb1b38e1 --- /dev/null +++ b/ansi-tests/restart-bind.lsp @@ -0,0 +1,34 @@ +;-*- Mode: Lisp -*- +;;;; Author: Paul Dietz +;;;; Created: Fri Mar 21 22:28:53 2003 +;;;; Contains: Tests for RESTART-BIND + +(in-package :cl-test) + +(deftest restart-bind.1 + (restart-bind () nil) + nil) + +(deftest restart-bind.2 + (restart-bind () (values))) + +(deftest restart-bind.3 + (restart-bind () (values 'a 'b 'c 'd 'e 'f)) + a b c d e f) + +(deftest restart-bind.4 + (block nil + (restart-bind () (return 'good) 'bad)) + good) + +(deftest restart-bind.5 + (block done + (tagbody + (restart-bind () (go 10) (return-from done 'bad)) + 10 + (return-from done 'good))) + good) + + + + -- GitLab