@@ -456,8 +456,7 @@ def __initialize_utm_coordinates(self):
456456 flattening = self .ellipsoid .flattening ,
457457 semi_major_axis = self .ellipsoid .semi_major_axis ,
458458 )
459- else :
460- # pragma: no cover
459+ else : # pragma: no cover
461460 warnings .warn (
462461 "UTM coordinates are not available for latitudes "
463462 "above 84 or below -80 degrees. The UTM conversions will fail."
@@ -712,8 +711,8 @@ def set_location(self, latitude, longitude):
712711
713712 if not isinstance (latitude , NUMERICAL_TYPES ) and isinstance (
714713 longitude , NUMERICAL_TYPES
715- ):
716- # pragma: no cover
714+ ): # pragma: no cover
715+
717716 raise TypeError ("Latitude and Longitude must be numbers!" )
718717
719718 # Store latitude and longitude
@@ -809,8 +808,8 @@ def max_expected_height(self):
809808
810809 @max_expected_height .setter
811810 def max_expected_height (self , value ):
812- if value < self .elevation :
813- raise ValueError ( # pragma: no cover
811+ if value < self .elevation : # pragma: no cover
812+ raise ValueError (
814813 "Max expected height cannot be lower than the surface elevation"
815814 )
816815 self ._max_expected_height = value
@@ -949,8 +948,8 @@ def get_elevation_from_topographic_profile(self, lat, lon):
949948 Elevation provided by the topographic data, in meters.
950949 """
951950 # TODO: refactor this method. pylint: disable=too-many-statements
952- if self .topographic_profile_activated is False :
953- raise ValueError ( # pragma: no cover
951+ if self .topographic_profile_activated is False : # pragma: no cover
952+ raise ValueError (
954953 "You must define a Topographic profile first, please use the "
955954 "Environment.set_topographic_profile() method first."
956955 )
@@ -1279,8 +1278,8 @@ def set_atmospheric_model( # pylint: disable=too-many-statements
12791278 self .process_forecast_reanalysis (dataset , dictionary )
12801279 else :
12811280 self .process_ensemble (dataset , dictionary )
1282- else :
1283- raise ValueError (f"Unknown model type '{ type } '." ) # pragma: no cover
1281+ else : # pragma: no cover
1282+ raise ValueError (f"Unknown model type '{ type } '." )
12841283
12851284 if type not in ["ensemble" ]:
12861285 # Ensemble already computed these values
@@ -2749,7 +2748,7 @@ def decimal_degrees_to_arc_seconds(angle):
27492748 return degrees , arc_minutes , arc_seconds
27502749
27512750
2752- if __name__ == "__main__" :
2751+ if __name__ == "__main__" : # pragma: no cover
27532752 import doctest
27542753
27552754 results = doctest .testmod ()
0 commit comments