/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_commands.py

  • Committer: Vincent Ladeuil
  • Date: 2010-03-01 09:08:27 UTC
  • mto: (5064.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 5065.
  • Revision ID: v.ladeuil+lp@free.fr-20100301090827-unqp82b4imjdn312
Really deprecate commands.shlex_split_unicode.

* test_commands.py:
(TestDeprecations): Ensure we get the deprecation warning.

* commands.py:
(shlex_split_unicode): Add deprecation decorator.

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
    config,
25
25
    errors,
26
26
    option,
 
27
    symbol_versioning,
27
28
    tests,
28
29
    )
29
30
from bzrlib.commands import display_command
323
324
        cmds = list(commands.all_command_names())
324
325
        self.assertEqual(['called'], hook_calls)
325
326
        self.assertSubset(['foo', 'bar'], cmds)
 
327
 
 
328
class TestDeprecations(tests.TestCase):
 
329
 
 
330
    def test_shlex_split_unicode_deprecation(self):
 
331
        res = self.applyDeprecated(
 
332
                symbol_versioning.deprecated_in((2, 2, 0)),
 
333
                commands.shlex_split_unicode, 'whatever')