@@ -1340,19 +1340,10 @@ def test_common_coord_when_datavars_all(self):
1340
1340
1341
1341
var_shape = ds [self .var_name ].shape
1342
1342
1343
- # shape pairs to be compared
1344
- shape_pairs = [
1345
- (var_shape , coord_shape ),
1346
- (coord_shape1 , coord_shape ),
1347
- (coord_shape2 , coord_shape )
1348
- ]
1349
- # tests to be applied to respective pairs
1350
- tests = [self .assertEqual ,
1351
- self .assertNotEqual , self .assertNotEqual ]
1352
-
1353
- for a_test , a_shape_pair in zip (tests , shape_pairs ):
1354
- a_test (* a_shape_pair )
1355
-
1343
+ self .assertEqual (var_shape , coord_shape )
1344
+ self .assertNotEqual (coord_shape1 , coord_shape )
1345
+ self .assertNotEqual (coord_shape2 , coord_shape )
1346
+
1356
1347
def test_common_coord_when_datavars_minimal (self ):
1357
1348
opt = 'minimal'
1358
1349
@@ -1366,18 +1357,9 @@ def test_common_coord_when_datavars_minimal(self):
1366
1357
1367
1358
var_shape = ds [self .var_name ].shape
1368
1359
1369
- # shape pairs to be compared
1370
- shape_pairs = [
1371
- (var_shape , coord_shape ),
1372
- (coord_shape1 , coord_shape ),
1373
- (coord_shape2 , coord_shape )
1374
- ]
1375
- # tests to be applied to respective pairs
1376
- tests = [self .assertNotEqual ,
1377
- self .assertEqual , self .assertEqual ]
1378
-
1379
- for a_test , a_shape_pair in zip (tests , shape_pairs ):
1380
- a_test (* a_shape_pair )
1360
+ self .assertNotEqual (var_shape , coord_shape )
1361
+ self .assertEqual (coord_shape1 , coord_shape )
1362
+ self .assertEqual (coord_shape2 , coord_shape )
1381
1363
1382
1364
def test_invalid_data_vars_value_should_fail (self ):
1383
1365
0 commit comments