Skip to content

Commit

Permalink
Black formatting fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
benjwadams committed Apr 15, 2024
1 parent dcd1edf commit 0f68486
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
3 changes: 1 addition & 2 deletions compliance_checker/cf/cf_1_6.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,8 +443,7 @@ def check_valid_range_and_valid_min_max_present(self, ds):
total = 0

for variable in ds.variables.values():
if (hasattr(variable, "valid_max") or
hasattr(variable, "valid_min")):
if hasattr(variable, "valid_max") or hasattr(variable, "valid_min"):
total += 1
# if there's also valid_range in addition to
# valid_min/valid_max, this is not compliant
Expand Down
10 changes: 6 additions & 4 deletions compliance_checker/tests/test_cf.py
Original file line number Diff line number Diff line change
Expand Up @@ -1300,7 +1300,9 @@ def test_check_time_coordinate(self):
# NB: >= 60 seconds is nonstandard, but isn't actually a CF requirement
# until CF 1.9 onwards
dataset.variables["time"].units = "months since 0-1-1 23:00:60"
dataset.variables["time"].climatology = (
dataset.variables[
"time"
].climatology = (
"nonexistent_variable_reference_only_used_to_test_year_zero_failure"
)
results = self.cf.check_time_coordinate(dataset)
Expand Down Expand Up @@ -2951,9 +2953,9 @@ def test_bad_lsid(self):
messages = results[0].msgs
assert results[0].value[0] < results[0].value[1]
assert len(messages) == 1
taxon_lsid[0] = (
"http://www.lsid.info/urn:lsid:marinespecies.org:taxname:99999999999"
)
taxon_lsid[
0
] = "http://www.lsid.info/urn:lsid:marinespecies.org:taxname:99999999999"
results = self.cf.check_taxa(dataset)
assert messages[0].startswith(
"Taxon id must match one of the following forms:",
Expand Down

0 comments on commit 0f68486

Please sign in to comment.