~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_workingtree/test_workingtree.py

MergeĀ lp:bzr.

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
        self.assertEqual(('filename', 'V', 'directory', 'file-id'),
122
122
                         result[0][:4])
123
123
 
 
124
    def test_get_config_stack(self):
 
125
        # Smoke test that all working trees succeed getting a config
 
126
        wt = self.make_branch_and_tree('.')
 
127
        conf = wt.get_config_stack()
 
128
        self.assertIsInstance(conf, config.Stack)
 
129
 
124
130
    def test_open_containing(self):
125
131
        branch = self.make_branch_and_tree('.').branch
126
132
        local_base = urlutils.local_path_from_url(branch.base)
1200
1206
 
1201
1207
    def test_set_in_branch(self):
1202
1208
        wt = self.make_wt_with_worth_saving_limit()
1203
 
        conf = config.BranchStack(wt.branch)
 
1209
        conf = wt.get_config_stack()
1204
1210
        conf.set('bzr.workingtree.worth_saving_limit', '20')
1205
1211
        self.assertEqual(20, wt._worth_saving_limit())
1206
1212
        ds = wt.current_dirstate()
1208
1214
 
1209
1215
    def test_invalid(self):
1210
1216
        wt = self.make_wt_with_worth_saving_limit()
1211
 
        conf = config.BranchStack(wt.branch)
 
1217
        conf = wt.get_config_stack()
1212
1218
        conf.set('bzr.workingtree.worth_saving_limit', 'a')
1213
1219
        # If the config entry is invalid, default to 10
1214
1220
        warnings = []