Update of /cvsroot/sqlobject/SQLObject/tests
In directory sc8-pr-cvs1:/tmp/cvs-serv1207/tests
Modified Files:
SQLObjectTest.py test.py
Log Message:
* Moved all SQL into DBConnection (_SO_* methods)
* A test case for RelatedJoin
* Created a DBM-based backend. Passes almost all tests!
* Incomplete Pickle-based backend (like DBM, only records are kept
in individual files... I'm not sure I want to use it, though).
Index: SQLObjectTest.py
===================================================================
RCS file: /cvsroot/sqlobject/SQLObject/tests/SQLObjectTest.py,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** SQLObjectTest.py 31 Mar 2003 05:51:28 -0000 1.3
--- SQLObjectTest.py 7 Apr 2003 01:13:56 -0000 1.4
***************
*** 8,11 ****
--- 8,13 ----
debug=0)
+ #__connection__ = DBMConnection('data')
+
class SQLObjectTest(unittest.TestCase):
Index: test.py
===================================================================
RCS file: /cvsroot/sqlobject/SQLObject/tests/test.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** test.py 6 Apr 2003 07:56:06 -0000 1.4
--- test.py 7 Apr 2003 01:13:57 -0000 1.5
***************
*** 9,25 ****
class Counter(SQLObject):
- create = """
- CREATE TABLE IF NOT EXISTS counter (
- id INT PRIMARY KEY AUTO_INCREMENT,
- number INT NOT NULL
- )
- """
-
- drop = """
- DROP TABLE IF EXISTS counter
- """
-
_columns = [
! Col('number'),
]
--- 9,14 ----
class Counter(SQLObject):
_columns = [
! IntCol('number', notNull=True),
]
***************
*** 57,74 ****
class Counter2(SQLObject):
- create = """
- CREATE TABLE IF NOT EXISTS counter2 (
- id INT PRIMARY KEY AUTO_INCREMENT,
- n1 INT NOT NULL,
- n2 INT NOT NULL
- )
- """
-
- drop = """
- DROP TABLE IF EXISTS counter2
- """
-
_columns = [
! 'n1', 'n2',
]
--- 46,52 ----
class Counter2(SQLObject):
_columns = [
! IntCol('n1', notNull=True),
! IntCol('n2', notNull=True),
]
|