# Copyright (c) 2017, JINGROW and Contributors
# License: MIT. See LICENSE
import jingrow
from jingrow.tests.utils import JingrowTestCase


class TestLetterHead(JingrowTestCase):
	def test_auto_image(self):
		letter_head = jingrow.get_pg(
			dict(pagetype="Letter Head", letter_head_name="Test", source="Image", image="/public/test.png")
		).insert()

		# test if image is automatically set
		self.assertTrue(letter_head.image in letter_head.content)
