Skip to content

Commit

Permalink
Use same black version as CI to format
Browse files Browse the repository at this point in the history
  • Loading branch information
seadowg committed Dec 9, 2019
1 parent f47a4bb commit d73166d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
8 changes: 6 additions & 2 deletions pyxform/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@
ATTRIBUTE = "attribute"
ALLOW_CHOICE_DUPLICATES = "allow_choice_duplicates"

BIND = "bind" # TODO: What should I do with the nested types? (readonly and relevant) # noqa
BIND = (
"bind"
) # TODO: What should I do with the nested types? (readonly and relevant) # noqa
MEDIA = "media"
CONTROL = "control"
APPEARANCE = "appearance"
Expand All @@ -59,7 +61,9 @@
# XLS Specific constants
LIST_NAME = "list name"
CASCADING_SELECT = "cascading_select"
TABLE_LIST = "table-list" # hyphenated because it goes in appearance, and convention for appearance column is dashes # noqa
TABLE_LIST = (
"table-list"
) # hyphenated because it goes in appearance, and convention for appearance column is dashes # noqa

# The following are the possible sheet names:
SURVEY = "survey"
Expand Down
2 changes: 1 addition & 1 deletion pyxform/tests/xls2json_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ class DefaultToSurveyTest(TestCase):
def test_default_sheet_name_to_survey(self):
xls_path = utils.path_to_text_fixture("survey_no_name.xlsx")
dict_value = xls_to_dict(xls_path)
print(json.dumps(dict_value))
print (json.dumps(dict_value))
self.assertTrue("survey" in json.dumps(dict_value))
self.assertTrue("state" in json.dumps(dict_value))
self.assertTrue("The State" in json.dumps(dict_value))
8 changes: 6 additions & 2 deletions pyxform/tests_v1/test_xmldata.py
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,9 @@ def test_can__reuse_csv__pulldata_then_selects(self):
| | select_one_from_file pain_locations.csv | pmonth | Location of worst pain this month. | |
| | select_one_from_file pain_locations.csv | pyear | Location of worst pain this year. | |
""" # noqa
expected = """<instance id="pain_locations" src="jr://file-csv/pain_locations.csv"/>""" # noqa
expected = (
"""<instance id="pain_locations" src="jr://file-csv/pain_locations.csv"/>"""
) # noqa
self.assertPyxformXform(
md=md, model__contains=[expected], run_odk_validate=True
)
Expand Down Expand Up @@ -318,7 +320,9 @@ def test_can__reuse_xml__external_then_selects(self):
| | select_one_from_file pain_locations.xml | pmonth | Location of worst pain this month. |
| | select_one_from_file pain_locations.xml | pyear | Location of worst pain this year. |
""" # noqa
expected = """<instance id="pain_locations" src="jr://file/pain_locations.xml"/>""" # noqa
expected = (
"""<instance id="pain_locations" src="jr://file/pain_locations.xml"/>"""
) # noqa
self.assertPyxformXform(
md=md, model__contains=[expected], run_odk_validate=True
)
Expand Down

0 comments on commit d73166d

Please sign in to comment.