1 ;;;; -*- Mode: Lisp; Syntax: ANSI-Common-Lisp; Base: 10; Package: umlisp -*-
2 ;;;; *************************************************************************
3 ;;;; FILE IDENTIFICATION
6 ;;;; Purpose: Regression suite for UMLisp
7 ;;;; Author: Kevin M. Rosenberg
8 ;;;; Date Started: May 2003
10 ;;;; $Id: tests.lisp,v 1.1 2003/05/02 18:47:53 kevin Exp $
12 ;;;; This file, part of UMLisp, is
13 ;;;; Copyright (c) 2000-2002 by Kevin M. Rosenberg, M.D.
15 ;;;; UMLisp users are granted the rights to distribute and use this software
16 ;;;; as governed by the terms of the GNU General Public License.
17 ;;;; *************************************************************************
19 (defpackage #:umlisp-tests
20 (:use #:umlisp #:cl #:rtest))
21 (in-package #:umlisp-tests)
23 (setf rtest::*catch-errors* nil)
27 (deftest qs.1 (umlisp::query-string 'mrcon '(cui lui))
28 "select CUI,LUI from MRCON")
30 (deftest qs.2 (umlisp::query-string 'mrcon '(cui lui) 0)
31 "select CUI,LUI from MRCON and KCUILRL <= 0")
33 (deftest qs.3 (umlisp::query-string 'mrcon '(cui lui) nil 'cui 5)
34 "select CUI,LUI from MRCON where CUI=5")
36 (deftest qs.4 (umlisp::query-string 'mrcon '(cui lui) nil 'kpfstr "Abc")
37 "select CUI,LUI from MRCON where KPFSTR='Abc'")
39 (deftest qs.5 (umlisp::query-string 'mrcon '(cui lui) 2 'cui 5 "limit 1")
40 "select CUI,LUI from MRCON where CUI=5 and KCUILRL <= 2 limit 1")
42 (deftest qs.6 (umlisp::query-string 'mrdef '(sab def) 2 'cui 39 'srl "limit 1")
43 "select SAB,DEF from MRDEF where CUI=39 and KSRL <= 2 limit 1")