Exemple #1
0
 def test_set_override_false(self):
     d = Definition({'name': 'test'})
     d.set('name', 'This is a test name', override=False)
     self.assertEqual(d.get('name'), 'test')
Exemple #2
0
 def test_set(self):
     d = Definition({'name': 'This is a test name'})
     d.set('name', 'test')
     self.assertEqual(d.get('name'), 'test')
Exemple #3
0
 def test_get_default_1(self):
     d = Definition({})
     self.assertEqual(d.get('name'), None)
Exemple #4
0
 def test_set_default_3(self):
     d = Definition({})
     d.set_default('name', 'test')
     self.assertEqual(d.get('name'), 'test')
Exemple #5
0
 def test_get(self):
     d = Definition({'name': 'test'})
     self.assertEqual(d.get('name'), 'test')