~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/blackbox/test_config.py

  • Committer: Ross Lagerwall
  • Date: 2012-08-07 06:32:51 UTC
  • mto: (6437.63.5 2.5)
  • mto: This revision was merged to the branch mainline in revision 6558.
  • Revision ID: rosslagerwall@gmail.com-20120807063251-x9p03ghg2ws8oqjc
Add bzrlib/locale to .bzrignore

bzrlib/locale is generated with ./setup.py build_mo which is in turn called
by ./setup.py build

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2010, 2011, 2012, 2016 Canonical Ltd
 
1
# Copyright (C) 2010 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
32
32
 
33
33
    def test_config_all(self):
34
34
        out, err = self.run_bzr(['config'])
35
 
        self.assertEqual('', out)
36
 
        self.assertEqual('', err)
 
35
        self.assertEquals('', out)
 
36
        self.assertEquals('', err)
37
37
 
38
38
    def test_remove_unknown_option(self):
39
39
        self.run_bzr_error(['The "file" configuration option does not exist',],
95
95
            """
96
96
            ''')
97
97
 
98
 
    def test_list_value_all(self):
 
98
    def test_list_all_values(self):
99
99
        config.option_registry.register(config.ListOption('list'))
100
100
        self.addCleanup(config.option_registry.remove, 'list')
101
101
        self.bazaar_config.set_user_option('list', [1, 'a', 'with, a comma'])
106
106
              list = 1, a, "with, a comma"
107
107
            ''')
108
108
 
109
 
    def test_list_value_one(self):
 
109
    def test_list_value_only(self):
110
110
        config.option_registry.register(config.ListOption('list'))
111
111
        self.addCleanup(config.option_registry.remove, 'list')
112
112
        self.bazaar_config.set_user_option('list', [1, 'a', 'with, a comma'])
115
115
            1, a, "with, a comma"
116
116
            ''')
117
117
 
118
 
    def test_registry_value_all(self):
119
 
        self.bazaar_config.set_user_option('bzr.transform.orphan_policy',
120
 
                                           u'move')
121
 
        script.run_script(self, '''\
122
 
            $ bzr config -d tree
123
 
            bazaar:
124
 
              [DEFAULT]
125
 
              bzr.transform.orphan_policy = move
126
 
            ''')
127
 
 
128
 
    def test_registry_value_one(self):
129
 
        self.bazaar_config.set_user_option('bzr.transform.orphan_policy',
130
 
                                           u'move')
131
 
        script.run_script(self, '''\
132
 
            $ bzr config -d tree bzr.transform.orphan_policy
133
 
            move
134
 
            ''')
135
 
 
136
118
    def test_bazaar_config(self):
137
119
        self.bazaar_config.set_user_option('hello', 'world')
138
120
        script.run_script(self, '''\
393
375
        clone.get_config_stack().set('test', 'clone')
394
376
        out, err = self.run_bzr(['config', '-d', ':parent', 'test'],
395
377
                                working_dir='clone')
396
 
        self.assertEqual('base\n', out)
 
378
        self.assertEquals('base\n', out)