Exemplo n.º 1
0
 def test_read_config_override_ignores(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\nignore = foo\n\n  bar\n')
         f.write('ignore-default-rules = yes\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE, ['foo', 'bar'])
Exemplo n.º 2
0
 def test_read_config_extra_ignores(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\nignore = foo\n  bar\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE,
                      ['default-ignore-rules', 'foo', 'bar'])
Exemplo n.º 3
0
 def test_read_config_extra_ignores(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\nignore = foo\n  bar\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE,
                      ['default-ignore-rules', 'foo', 'bar'])
Exemplo n.º 4
0
 def test_read_config_override_ignores(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\nignore = foo\n\n  bar\n')
         f.write('ignore-default-rules = yes\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE,
                      ['foo', 'bar'])
Exemplo n.º 5
0
 def test_read_config_no_option(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE, ['default-ignore-rules'])
Exemplo n.º 6
0
 def test_read_config_no_config(self):
     import check_manifest
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE, ['default-ignore-rules'])
Exemplo n.º 7
0
 def test_read_config_no_option(self):
     import check_manifest
     with open('setup.cfg', 'w') as f:
         f.write('[check-manifest]\n')
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE, ['default-ignore-rules'])
Exemplo n.º 8
0
 def test_read_config_no_config(self):
     import check_manifest
     check_manifest.read_config()
     self.assertEqual(check_manifest.IGNORE, ['default-ignore-rules'])