本文整理匯總了Python中onadata.apps.main.tests.test_base.TestBase._publish_xls_file方法的典型用法代碼示例。如果您正苦於以下問題:Python TestBase._publish_xls_file方法的具體用法?Python TestBase._publish_xls_file怎麽用?Python TestBase._publish_xls_file使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類onadata.apps.main.tests.test_base.TestBase
的用法示例。
在下文中一共展示了TestBase._publish_xls_file方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: _publish_transportation_id_string_starts_with_number_form
# 需要導入模塊: from onadata.apps.main.tests.test_base import TestBase [as 別名]
# 或者: from onadata.apps.main.tests.test_base.TestBase import _publish_xls_file [as 別名]
def _publish_transportation_id_string_starts_with_number_form(self):
xls_path = os.path.join(self.this_directory, "fixtures",
"transportation",
"transportation.id_starts_with_num.xls")
count = XForm.objects.count()
TestBase._publish_xls_file(self, xls_path)
self.assertEqual(XForm.objects.count(), count + 1)
self.xform = XForm.objects.all().reverse()[0]
示例2: _publish_survey
# 需要導入模塊: from onadata.apps.main.tests.test_base import TestBase [as 別名]
# 或者: from onadata.apps.main.tests.test_base.TestBase import _publish_xls_file [as 別名]
def _publish_survey(self):
self.this_directory = os.path.dirname(__file__)
xls_path = self._fixture_path("gps", "gps.xls")
TestBase._publish_xls_file(self, xls_path)