~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_commands.py

  • Committer: Patch Queue Manager
  • Date: 2016-02-01 19:13:13 UTC
  • mfrom: (6614.2.2 trunk)
  • Revision ID: pqm@pqm.ubuntu.com-20160201191313-wdfvmfff1djde6oq
(vila) Release 2.7.0 (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005-2011 Canonical Ltd
 
1
# Copyright (C) 2005-2012, 2016 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
98
98
            # We override the run() command method so we can observe the
99
99
            # overrides from inside.
100
100
            c = config.GlobalStack()
101
 
            self.assertEquals('12', c.get('xx'))
102
 
            self.assertEquals('foo', c.get('yy'))
 
101
            self.assertEqual('12', c.get('xx'))
 
102
            self.assertEqual('foo', c.get('yy'))
103
103
        self.overrideAttr(builtins.cmd_rocks, 'run', run)
104
104
        self.run_bzr(['rocks', '-Oxx=12', '-Oyy=foo'])
105
105
        c = config.GlobalStack()
106
106
        # Ensure that we don't leak outside of the command
107
 
        self.assertEquals(None, c.get('xx'))
108
 
        self.assertEquals(None, c.get('yy'))
 
107
        self.assertEqual(None, c.get('xx'))
 
108
        self.assertEqual(None, c.get('yy'))
109
109
 
110
110
 
111
111
class TestInvokedAs(tests.TestCase):
117
117
        # get one from the real get_cmd_object.
118
118
        c = commands.get_cmd_object('ci')
119
119
        self.assertIsInstance(c, builtins.cmd_commit)
120
 
        self.assertEquals(c.invoked_as, 'ci')
 
120
        self.assertEqual(c.invoked_as, 'ci')
121
121
 
122
122
 
123
123
class TestGetAlias(tests.TestCase):