From 5b8dc78d2e158b31d31b67983f012734483c4df9 Mon Sep 17 00:00:00 2001 From: Roger Hunwicks Date: Tue, 28 Mar 2017 06:39:01 +0200 Subject: [PATCH 1/2] Fix #87 validation of external instances --- pyxform/survey.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyxform/survey.py b/pyxform/survey.py index c5ef9627f..5d9507711 100644 --- a/pyxform/survey.py +++ b/pyxform/survey.py @@ -162,7 +162,7 @@ def _generate_from_file_instances(self): file_id, file_extension = os.path.splitext(itemset) yield node( "instance", - node("root", node("item", node("name"), node("label"))), + node("root", node("item", node("name", "_"), node("label", "_"))), id=file_id, src="jr://file-%s/%s" % (file_extension[1:], itemset) ) From de377ef32fcae1a0c5a1363e3a379381ee21099a Mon Sep 17 00:00:00 2001 From: Roger Hunwicks Date: Wed, 29 Mar 2017 08:26:33 +0200 Subject: [PATCH 2/2] Fix external instance tests - see #87 --- .../test_support_external_instances.py | 27 ++++++++++--------- 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/pyxform/tests_v1/test_support_external_instances.py b/pyxform/tests_v1/test_support_external_instances.py index e8d5f8f1f..34ae8b6a9 100644 --- a/pyxform/tests_v1/test_support_external_instances.py +++ b/pyxform/tests_v1/test_support_external_instances.py @@ -16,8 +16,8 @@ def test_external_csv_instances(self): """ - - """, # noqa @@ -26,14 +26,15 @@ def test_external_csv_instances(self): """ - - """, # noqa '', '', # noqa ], + run_odk_validate=True, ) @@ -85,8 +87,8 @@ def test_external_xml_instances(self): """ - - """, # noqa @@ -95,14 +97,15 @@ def test_external_xml_instances(self): """ - - """, # noqa '