# Copyright (c) 2015, Xhive Global Ltd. and Contributors
# License: MIT. See LICENSE
import xhiveframework
from xhiveframework.tests.utils import XhiveFrameworkTestCase

test_records = xhiveframework.get_test_records("Page")


class TestPage(XhiveFrameworkTestCase):
	def test_naming(self):
		self.assertRaises(
			xhiveframework.NameError,
			xhiveframework.get_doc(dict(doctype="Page", page_name="DocType", module="Core")).insert,
		)
		self.assertRaises(
			xhiveframework.NameError,
			xhiveframework.get_doc(dict(doctype="Page", page_name="Settings", module="Core")).insert,
		)
