diff options
Diffstat (limited to 'test/tables.py')
-rw-r--r-- | test/tables.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/test/tables.py b/test/tables.py index b1beff867..97363aa92 100644 --- a/test/tables.py +++ b/test/tables.py @@ -110,16 +110,22 @@ def data(): dict(keyword_id=6, name='round'), dict(keyword_id=7, name='square') ) + + # this many-to-many table has the keywords inserted + # in primary key order, to appease the unit tests. + # this is because postgres, oracle, and sqlite all support + # true insert-order row id, but of course our pal MySQL does not, + # so the best it can do is order by, well something, so there you go. itemkeywords.insert().execute( dict(keyword_id=2, item_id=1), dict(keyword_id=2, item_id=2), dict(keyword_id=4, item_id=1), dict(keyword_id=6, item_id=1), - dict(keyword_id=7, item_id=2), - dict(keyword_id=6, item_id=3), - dict(keyword_id=3, item_id=3), dict(keyword_id=5, item_id=2), - dict(keyword_id=4, item_id=3) + dict(keyword_id=3, item_id=3), + dict(keyword_id=4, item_id=3), + dict(keyword_id=7, item_id=2), + dict(keyword_id=6, item_id=3) ) db.commit() |