@@ -116,7 +116,7 @@ def test_encode_decode_array_2():
116
116
assert [df .get_config ()] == meta_dec ['filters' ]
117
117
118
118
119
- def test_encode_decode_array_unstructured ():
119
+ def test_encode_decode_array_dtype_shape ():
120
120
121
121
meta = dict (
122
122
shape = (100 ,),
@@ -146,12 +146,10 @@ def test_encode_decode_array_unstructured():
146
146
# test decoding
147
147
meta_dec = decode_array_metadata (meta_enc )
148
148
assert ZARR_FORMAT == meta_dec ['zarr_format' ]
149
- # NOTE(onalant): https://github.com/zarr-developers/zarr/pull/296#issuecomment-417608487
150
- # To maintain consistency with numpy unstructured arrays, unpack dimensions into shape.
149
+ # to maintain consistency with numpy unstructured arrays, unpack dimensions into shape
151
150
assert meta ['shape' ] + meta ['dtype' ].shape == meta_dec ['shape' ]
152
151
assert meta ['chunks' ] == meta_dec ['chunks' ]
153
- # NOTE(onalant): https://github.com/zarr-developers/zarr/pull/296#issuecomment-417608487
154
- # To maintain consistency with numpy unstructured arrays, unpack dtypes.
152
+ # to maintain consistency with numpy unstructured arrays, unpack dtypes
155
153
assert meta ['dtype' ].base == meta_dec ['dtype' ]
156
154
assert meta ['compressor' ] == meta_dec ['compressor' ]
157
155
assert meta ['order' ] == meta_dec ['order' ]
@@ -189,12 +187,10 @@ def test_encode_decode_array_structured():
189
187
# test decoding
190
188
meta_dec = decode_array_metadata (meta_enc )
191
189
assert ZARR_FORMAT == meta_dec ['zarr_format' ]
192
- # NOTE(onalant): https://github.com/zarr-developers/zarr/pull/296#issuecomment-417608487
193
- # To maintain consistency with numpy unstructured arrays, unpack dimensions into shape.
190
+ # to maintain consistency with numpy unstructured arrays, unpack dimensions into shape
194
191
assert meta ['shape' ] + meta ['dtype' ].shape == meta_dec ['shape' ]
195
192
assert meta ['chunks' ] == meta_dec ['chunks' ]
196
- # NOTE(onalant): https://github.com/zarr-developers/zarr/pull/296#issuecomment-417608487
197
- # To maintain consistency with numpy unstructured arrays, unpack dtypes.
193
+ # to maintain consistency with numpy unstructured arrays, unpack dimensions into shape
198
194
assert meta ['dtype' ].base == meta_dec ['dtype' ]
199
195
assert meta ['compressor' ] == meta_dec ['compressor' ]
200
196
assert meta ['order' ] == meta_dec ['order' ]
0 commit comments