Exemple #1
0
 def test_coords_iris_to_esmpy_1d_circular(self):
     """Test coord conversion with 1d coords and circular longitudes."""
     (esmpy_lat, esmpy_lon, esmpy_lat_corners,
      esmpy_lon_corners) = coords_iris_to_esmpy(self.lat_1d, self.lon_1d,
                                                True)
     self.assert_array_equal(esmpy_lat, self.expected_esmpy_lat)
     self.assert_array_equal(esmpy_lon, self.expected_esmpy_lon)
     self.assert_array_equal(esmpy_lat_corners,
                             self.expected_esmpy_lat_corners[:-1])
     self.assert_array_equal(esmpy_lon_corners,
                             self.expected_esmpy_lon_corners[:-1])
Exemple #2
0
 def test_coords_iris_to_esmpy_2d_non_circular(self):
     """Test coord conversion with 2d coords and non circular longitudes."""
     (esmpy_lat, esmpy_lon, esmpy_lat_corners,
      esmpy_lon_corners) = coords_iris_to_esmpy(self.lat_2d, self.lon_2d,
                                                False)
     self.assert_array_equal(esmpy_lat, self.expected_esmpy_lat)
     self.assert_array_equal(esmpy_lon, self.expected_esmpy_lon)
     self.assert_array_equal(esmpy_lat_corners,
                             self.expected_esmpy_lat_corners)
     self.assert_array_equal(esmpy_lon_corners,
                             self.expected_esmpy_lon_corners)
Exemple #3
0
 def test_coords_iris_to_esmpy_call_guess_bounds(self):
     """Test coord conversion with missing bounds."""
     coords_iris_to_esmpy(self.lat_1d_no_bounds, self.lon_1d, True)
     self.lat_1d_no_bounds.guess_bounds.assert_called_once()