brotherton-erpnext/erpnext/tests/test_regional.py
2022-02-25 11:36:18 +05:30

19 lines
348 B
Python

import unittest
import frappe
import erpnext
@erpnext.allow_regional
def test_method():
return 'original'
class TestInit(unittest.TestCase):
def test_regional_overrides(self):
frappe.flags.country = 'Maldives'
self.assertEqual(test_method(), 'original')
frappe.flags.country = 'France'
self.assertEqual(test_method(), 'overridden')