~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_config.py

(vila) Revise legal option names to be less drastic. (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
2237
2237
        self.assertTrue(self.is_valid('__bar__'))
2238
2238
        self.assertTrue(self.is_valid('a_'))
2239
2239
        self.assertTrue(self.is_valid('a1'))
 
2240
        # Don't break bzr-svn for no good reason
 
2241
        self.assertTrue(self.is_valid('guessed-layout'))
2240
2242
 
2241
2243
    def test_invalid_names(self):
2242
2244
        self.assertFalse(self.is_valid(' foo'))
2250
2252
        self.assertFalse(self.is_valid('{}'))
2251
2253
        self.assertFalse(self.is_valid('{a}'))
2252
2254
        self.assertFalse(self.is_valid('a\n'))
 
2255
        self.assertFalse(self.is_valid('-'))
 
2256
        self.assertFalse(self.is_valid('-a'))
 
2257
        self.assertFalse(self.is_valid('a-'))
 
2258
        self.assertFalse(self.is_valid('a--a'))
2253
2259
 
2254
2260
    def assertSingleGroup(self, reference):
2255
2261
        # the regexp is used with split and as such should match the reference