projects
/
clsql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
44cfc62
)
r1774: more implementation
author
Kevin M. Rosenberg
<kevin@rosenberg.net>
Mon, 8 Apr 2002 02:52:39 +0000
(
02:52
+0000)
committer
Kevin M. Rosenberg
<kevin@rosenberg.net>
Mon, 8 Apr 2002 02:52:39 +0000
(
02:52
+0000)
test-suite/tester-clsql.cl
patch
|
blob
|
history
diff --git
a/test-suite/tester-clsql.cl
b/test-suite/tester-clsql.cl
index 74c504f0acc3f04071815a9597e61c9501d8e3ad..fd91df1cf46f5275a7870678291ddec193877a78 100644
(file)
--- a/
test-suite/tester-clsql.cl
+++ b/
test-suite/tester-clsql.cl
@@
-7,7
+7,7
@@
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Mar 2002
;;;;
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Mar 2002
;;;;
-;;;; $Id: tester-clsql.cl,v 1.
1 2002/04/08 02:50:28
kevin Exp $
+;;;; $Id: tester-clsql.cl,v 1.
2 2002/04/08 02:52:39
kevin Exp $
;;;;
;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
;;;;
;;;;
;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
;;;;
@@
-16,14
+16,9
@@
;;;; (http://opensource.franz.com/preamble.html), also known as the LLGPL.
;;;; *************************************************************************
;;;; (http://opensource.franz.com/preamble.html), also known as the LLGPL.
;;;; *************************************************************************
-(error "Not yet implemented")
-
(declaim (optimize (debug 3) (speed 3) (safety 1) (compilation-speed 0)))
(in-package :cl-user)
(declaim (optimize (debug 3) (speed 3) (safety 1) (compilation-speed 0)))
(in-package :cl-user)
-(defvar *config-pathname* (make-pathname :name "test"
- :type "config"
- :defaults *load-truename*))
(unless (find-package :util.test)
(load (make-pathname :name "acl-compat-tester" :type "cl"
:defaults *load-truename*)))
(unless (find-package :util.test)
(load (make-pathname :name "acl-compat-tester" :type "cl"
:defaults *load-truename*)))
@@
-31,17
+26,22
@@
(in-package :clsql-user)
(use-package :util.test)
(in-package :clsql-user)
(use-package :util.test)
-(def-test-fixture clsql-fixture ()
+(defvar *config-pathname* (make-pathname :name "test"
+ :type "config"
+ :defaults *load-truename*))
+
+
+(defclass conn-specs ()
((aodbc-spec :accessor aodbc-spec)
(mysql-spec :accessor mysql-spec)
(pgsql-spec :accessor pgsql-spec)
(pgsql-socket-spec :accessor pgsql-socket-spec))
(:documentation "Test fixture for CLSQL testing"))
((aodbc-spec :accessor aodbc-spec)
(mysql-spec :accessor mysql-spec)
(pgsql-spec :accessor pgsql-spec)
(pgsql-socket-spec :accessor pgsql-socket-spec))
(:documentation "Test fixture for CLSQL testing"))
-(defvar *config-pathname* (make-pathname :name "test"
- :type "config"
- :defaults *load-truename*))
-(defmethod setup ((fix c
lsql-fixture
))
+
+(error "Not yet implemented")
+
+(defmethod setup ((fix c
onn-specs
))
(if (probe-file *config-pathname*)
(let (config)
(with-open-file (stream *config-pathname* :direction :input)
(if (probe-file *config-pathname*)
(let (config)
(with-open-file (stream *config-pathname* :direction :input)
@@
-53,19
+53,19
@@
(cadr (assoc :postgresql-socket config))))
(error "XPTest Config file ~S not found" *config-pathname*)))
(cadr (assoc :postgresql-socket config))))
(error "XPTest Config file ~S not found" *config-pathname*)))
-(defmethod teardown ((fix c
lsql-fixture
))
+(defmethod teardown ((fix c
onn-specs
))
t)
t)
-(defmethod mysql-table-test ((test c
lsql-fixture
))
+(defmethod mysql-table-test ((test c
onn-specs
))
(test-table (mysql-spec test) :mysql))
(test-table (mysql-spec test) :mysql))
-(defmethod aodbc-table-test ((test c
lsql-fixture
))
+(defmethod aodbc-table-test ((test c
onn-specs
))
(test-table (aodbc-spec test) :aodbc))
(test-table (aodbc-spec test) :aodbc))
-(defmethod pgsql-table-test ((test c
lsql-fixture
))
+(defmethod pgsql-table-test ((test c
onn-specs
))
(test-table (pgsql-spec test) :postgresql))
(test-table (pgsql-spec test) :postgresql))
-(defmethod pgsql-socket-table-test ((test c
lsql-fixture
))
+(defmethod pgsql-socket-table-test ((test c
onn-specs
))
(test-table (pgsql-socket-spec test) :postgresql-socket))
(test-table (pgsql-socket-spec test) :postgresql-socket))
@@
-103,7
+103,7
@@
(disconnect :database db)))))
(disconnect :database db)))))
-(defmethod mysql-low-level ((test c
lsql-fixture
))
+(defmethod mysql-low-level ((test c
onn-specs
))
(let ((spec (mysql-spec test)))
(when spec
(let ((db (clsql-mysql::database-connect spec :mysql)))
(let ((spec (mysql-spec test)))
(when spec
(let ((db (clsql-mysql::database-connect spec :mysql)))
@@
-127,22
+127,22
@@
(make-test-suite
"CLSQL Test Suite"
"Basic test suite for database operations."
(make-test-suite
"CLSQL Test Suite"
"Basic test suite for database operations."
- ("MySQL Low Level Interface" 'c
lsql-fixture
+ ("MySQL Low Level Interface" 'c
onn-specs
:test-thunk 'mysql-low-level
:description "A test of MySQL low-level interface")
:test-thunk 'mysql-low-level
:description "A test of MySQL low-level interface")
- ("MySQL Table" 'c
lsql-fixture
+ ("MySQL Table" 'c
onn-specs
:test-thunk 'mysql-table-test
:description "A test of MySQL")
:test-thunk 'mysql-table-test
:description "A test of MySQL")
- ("PostgreSQL Table" 'c
lsql-fixture
+ ("PostgreSQL Table" 'c
onn-specs
:test-thunk 'pgsql-table-test
:description "A test of PostgreSQL tables")
:test-thunk 'pgsql-table-test
:description "A test of PostgreSQL tables")
- ("PostgreSQL Socket Table" 'c
lsql-fixture
+ ("PostgreSQL Socket Table" 'c
onn-specs
:test-thunk 'pgsql-socket-table-test
:description "A test of PostgreSQL Socket tables")
))
#+allegro
:test-thunk 'pgsql-socket-table-test
:description "A test of PostgreSQL Socket tables")
))
#+allegro
-(add-test (make-test-case "AODBC table test" 'c
lsql-fixture
+(add-test (make-test-case "AODBC table test" 'c
onn-specs
:test-thunk 'aodbc-table-test
:description "Test AODBC table")
clsql-test-suite)
:test-thunk 'aodbc-table-test
:description "Test AODBC table")
clsql-test-suite)