Exemple #1
0
 def test_collection(self):
     collection = {
         "h1": normal_h1(),
         "h2": normal_h2()
     }
     message = write_many(collection)
     collection2 = read_many(message)
     assert collection == collection2
Exemple #2
0
 def test_normal(self):
     assert isinstance(examples.normal_h1(), Histogram1D)
     assert isinstance(examples.normal_h2(), Histogram2D)
     assert isinstance(examples.normal_h3(), HistogramND)
Exemple #3
0
 def test_simple(self):
     from physt import examples
     assert examples.normal_h2().dtype == np.dtype(np.int64)
Exemple #4
0
 def test_h2(self):
     H = normal_h2()
     message = write(H)
     H_ = read(message)
     assert H_ == H
Exemple #5
0
 def test_normal(self):
     assert isinstance(examples.normal_h1(), Histogram1D)
     assert isinstance(examples.normal_h2(), Histogram2D)
     assert isinstance(examples.normal_h3(), HistogramND)