예제 #1
0
파일: test_edn.py 프로젝트: jml/edn
 def test_custom(self):
     result = make_tagged_value(
         {Symbol('foo'): lambda x: list(reversed(x))},
         Symbol('foo'), 'bar')
     self.assertEqual(['r', 'a', 'b'], result)
예제 #2
0
파일: test_edn.py 프로젝트: jml/edn
 def test_default(self):
     result = make_tagged_value({}, Symbol('foo'), 'bar')
     self.assertEqual(TaggedValue(Symbol('foo'), 'bar'), result)