Skip to content

Commit dd57664

Browse files
committed
same for this one
1 parent e5430fd commit dd57664

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

tests/test_reductionist_json.py

+7-2
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,18 @@
44
import numpy as np
55

66
from activestorage import reductionist
7+
from activestorage.active import load_from_s3
8+
from activestorage.config import *
79
from test_bigger_data import save_cl_file_with_a
810

911
import json
1012

1113
class MockActive:
12-
def __init__(self, f,v):
13-
self.f = pyfive.File(f)
14+
def __init__(self, f, v):
15+
if USE_S3:
16+
self.f = load_from_s3(f)
17+
else:
18+
self.f = pyfive.File(f)
1419
ds = self.f[v]
1520
self.dtype = np.dtype(ds.dtype)
1621
self.array = pyfive.ZarrArrayStub(ds.shape, ds.chunks or ds.shape)

0 commit comments

Comments
 (0)