File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1194,6 +1194,26 @@ async def test_invalid_chunk_encoding(store: MemoryStore) -> None:
11941194 filters = "nonexistent_filter_name" ,
11951195 )
11961196
1197+ # string representation of a codec is only supported if codec has no required arguments
1198+ msg = "Delta.__init__() missing 1 required positional argument: 'dtype'"
1199+ with pytest .raises (TypeError , match = re .escape (msg )):
1200+ await create_array (
1201+ store = store ,
1202+ dtype = "uint8" ,
1203+ shape = (10 ,),
1204+ zarr_format = 2 ,
1205+ filters = "delta" ,
1206+ )
1207+ msg = "TransposeCodec.__init__() missing 1 required keyword-only argument: 'order'"
1208+ with pytest .raises (TypeError , match = re .escape (msg )):
1209+ await create_array (
1210+ store = store ,
1211+ dtype = "uint8" ,
1212+ shape = (10 ,),
1213+ zarr_format = 3 ,
1214+ filters = "transpose" ,
1215+ )
1216+
11971217 @staticmethod
11981218 @pytest .mark .parametrize ("dtype" , ["uint8" , "float32" , "str" ])
11991219 async def test_default_filters_compressors (
You can’t perform that action at this time.
0 commit comments