/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar
2729.2.2 by Martin Pool
Start moving inventory tests into per-inventory module
1
# Copyright (C) 2005, 2006, 2007 Canonical Ltd
2729.2.1 by Martin Pool
Start adding per-inventory tests
2
#
3
# This program is free software; you can redistribute it and/or modify
4
# it under the terms of the GNU General Public License as published by
5
# the Free Software Foundation; either version 2 of the License, or
6
# (at your option) any later version.
7
#
8
# This program is distributed in the hope that it will be useful,
9
# but WITHOUT ANY WARRANTY; without even the implied warranty of
10
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
# GNU General Public License for more details.
12
#
13
# You should have received a copy of the GNU General Public License
14
# along with this program; if not, write to the Free Software
4183.7.1 by Sabin Iacob
update FSF mailing address
15
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
2729.2.1 by Martin Pool
Start adding per-inventory tests
16
17
"""Tests for different inventory implementations"""
18
4084.5.1 by Robert Collins
Bulk update all test adaptation into a single approach, using multiply_tests rather than test adapters.
19
from bzrlib.tests import multiply_tests
2729.2.1 by Martin Pool
Start adding per-inventory tests
20
3302.9.18 by Vincent Ladeuil
bzrlib.tests.inventory_implementations and
21
def load_tests(basic_tests, module, loader):
2729.2.1 by Martin Pool
Start adding per-inventory tests
22
    """Generate suite containing all parameterized tests"""
23
    modules_to_test = [
3302.9.18 by Vincent Ladeuil
bzrlib.tests.inventory_implementations and
24
        'bzrlib.tests.inventory_implementations.basics',
25
        ]
4084.5.1 by Robert Collins
Bulk update all test adaptation into a single approach, using multiply_tests rather than test adapters.
26
    from bzrlib.inventory import Inventory
27
    scenarios = [('Inventory', {'inventory_class':Inventory})]
3302.9.27 by Vincent Ladeuil
Fixed as per Ian's review.
28
    # add the tests for the sub modules
4084.5.1 by Robert Collins
Bulk update all test adaptation into a single approach, using multiply_tests rather than test adapters.
29
    return multiply_tests(loader.loadTestsFromModuleNames(modules_to_test),
30
        scenarios, basic_tests)