Пример #1
0
 def test_render_moustache_bad_key(self):
     self.assertEqual(apply_config.render_moustache("{{badkey}}", {}), u'')
Пример #2
0
 def test_render_moustache(self):
     self.assertEqual(apply_config.render_moustache("ab{{x.a}}cd", {
                      "x": {"a": "123"}}), "ab123cd")
Пример #3
0
 def test_render_moustache_bad_key(self):
     self.assertEqual(u'', apply_config.render_moustache("{{badkey}}", {}))
Пример #4
0
 def test_render_moustache_none(self):
     self.assertEqual(
         'foo: ',
         apply_config.render_moustache("foo: {{foo}}", {'foo': None}))
Пример #5
0
 def test_render_moustache(self):
     self.assertEqual(
         "ab123cd",
         apply_config.render_moustache("ab{{x.a}}cd", {"x": {
             "a": "123"
         }}))