Mercurial > p > roundup > code
comparison test/test_db.py @ 862:37fb48c3a136
Did some old TODOs
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Sun, 14 Jul 2002 06:06:34 +0000 |
| parents | 2df32a73eb45 |
| children | e8162a199d81 |
comparison
equal
deleted
inserted
replaced
| 861:68cef2bb929d | 862:37fb48c3a136 |
|---|---|
| 13 # BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS | 13 # BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS |
| 14 # FOR A PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" | 14 # FOR A PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" |
| 15 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, | 15 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
| 16 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. | 16 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
| 17 # | 17 # |
| 18 # $Id: test_db.py,v 1.29 2002-07-14 04:03:15 richard Exp $ | 18 # $Id: test_db.py,v 1.30 2002-07-14 06:06:34 richard Exp $ |
| 19 | 19 |
| 20 import unittest, os, shutil, time | 20 import unittest, os, shutil, time |
| 21 | 21 |
| 22 from roundup.hyperdb import String, Password, Link, Multilink, Date, \ | 22 from roundup.hyperdb import String, Password, Link, Multilink, Date, \ |
| 23 Interval, DatabaseError | 23 Interval, DatabaseError |
| 199 # invalid multilink index | 199 # invalid multilink index |
| 200 ar(IndexError, self.db.issue.create, title='foo', status='1', | 200 ar(IndexError, self.db.issue.create, title='foo', status='1', |
| 201 nosy=['10']) | 201 nosy=['10']) |
| 202 | 202 |
| 203 # | 203 # |
| 204 # key property | |
| 205 # | |
| 206 # key must be a String | |
| 207 ar(TypeError, self.db.user.setkey, 'password') | |
| 208 # key must exist | |
| 209 ar(KeyError, self.db.user.setkey, 'fubar') | |
| 210 | |
| 211 # | |
| 204 # class get | 212 # class get |
| 205 # | 213 # |
| 206 # invalid node id | 214 # invalid node id |
| 207 ar(IndexError, self.db.issue.get, '1', 'title') | 215 ar(IndexError, self.db.issue.get, '1', 'title') |
| 208 # invalid property name | 216 # invalid property name |
| 522 | 530 |
| 523 return unittest.TestSuite(l) | 531 return unittest.TestSuite(l) |
| 524 | 532 |
| 525 # | 533 # |
| 526 # $Log: not supported by cvs2svn $ | 534 # $Log: not supported by cvs2svn $ |
| 535 # Revision 1.29 2002/07/14 04:03:15 richard | |
| 536 # Implemented a switch to disable journalling for a Class. CGI session | |
| 537 # database now uses it. | |
| 538 # | |
| 527 # Revision 1.28 2002/07/14 02:16:29 richard | 539 # Revision 1.28 2002/07/14 02:16:29 richard |
| 528 # Fixes for the metakit backend (removed the cut-n-paste IssueClass, removed | 540 # Fixes for the metakit backend (removed the cut-n-paste IssueClass, removed |
| 529 # a special case for it in testing) | 541 # a special case for it in testing) |
| 530 # | 542 # |
| 531 # Revision 1.27 2002/07/14 02:05:54 richard | 543 # Revision 1.27 2002/07/14 02:05:54 richard |
