Skip to content

Commit

Permalink
Testing caps of labels
Browse files Browse the repository at this point in the history
re: SEL-Columbia#76
Certain column names can have lower-cased equivalent aliases
  • Loading branch information
dorey committed Feb 27, 2015
1 parent 99e637a commit 0d90be2
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions pyxform/tests_v1/test_xlsform_headers.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from pyxform_test_case import PyxformTestCase


class XlsFormHeadersTest(PyxformTestCase):
def test_label_caps_alternatives(self):
'''
re: https://github.com/SEL-Columbia/pyxform/issues/76
Capitalization of 'label' column can lead to confusing errors.
'''
s1 = self.md_to_pyxform_survey("""
| survey | | | |
| | type | name | label |
| | note | q | Q |
""")
s2 = self.md_to_pyxform_survey("""
| survey | | | |
| | type | name | Label | # <-- note: capital L
| | note | q | Q |
""")
self.assertEqual(s1.to_xml(), s2.to_xml())

0 comments on commit 0d90be2

Please sign in to comment.