diff --git a/openerp/addons/base/base.sql b/openerp/addons/base/base.sql index 0a8f50c24bf..f2cb77709ed 100644 --- a/openerp/addons/base/base.sql +++ b/openerp/addons/base/base.sql @@ -348,9 +348,9 @@ CREATE TABLE ir_model_data ( ); -- Records foreign keys and constraints installed by a module (so they can be --- removed them when the module is uninstalled): --- - for a foreign key: type 'f', --- - for a constraint: type 'u'. +-- removed when the module is uninstalled): +-- - for a foreign key: type is 'f', +-- - for a constraint: type is 'u' (this is the convention PostgreSQL uses). CREATE TABLE ir_model_constraint ( id serial NOT NULL, create_uid integer, @@ -366,7 +366,7 @@ CREATE TABLE ir_model_constraint ( ); -- Records relation tables (i.e. implementing many2many) installed by a module --- (so they can be removed them when the module is uninstalled). +-- (so they can be removed when the module is uninstalled). CREATE TABLE ir_model_relation ( id serial NOT NULL, create_uid integer, diff --git a/openerp/tests/test_uninstall.py b/openerp/tests/test_uninstall.py index 514042188a9..1f74b660ce0 100644 --- a/openerp/tests/test_uninstall.py +++ b/openerp/tests/test_uninstall.py @@ -1,12 +1,5 @@ # -*- coding: utf-8 -*- -# Run with one of these commands: -# > OPENERP_ADDONS_PATH='../../addons/trunk' OPENERP_PORT=8069 \ -# OPENERP_DATABASE=yy PYTHONPATH=. python tests/test_ir_sequence.py -# > OPENERP_ADDONS_PATH='../../addons/trunk' OPENERP_PORT=8069 \ -# OPENERP_DATABASE=yy nosetests tests/test_ir_sequence.py -# > OPENERP_ADDONS_PATH='../../../addons/trunk' OPENERP_PORT=8069 \ -# OPENERP_DATABASE=yy PYTHONPATH=../:. unit2 test_ir_sequence -# This assume an existing database. +# This assumes an existing but uninitialized database. import psycopg2 import unittest2 @@ -77,7 +70,7 @@ class test_uninstall(unittest2.TestCase): assert search_registry('ir.model.fields', [('model', '=', 'test_uninstall.model')]) - def test_02_install(self): + def test_02_uninstall(self): """ Check a few things showing the module is uninstalled. """ uninstall_module('test_uninstall') assert not get_module('test_uninstall.model')