From 1223968e3823ad7f6bbe1ae8bffc0fe7845a25d5 Mon Sep 17 00:00:00 2001 From: Lindsey Gray Date: Wed, 23 Dec 2020 21:58:19 -0600 Subject: [PATCH] add test for the problem cited in 394 --- tests/test_hist_tools.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/test_hist_tools.py b/tests/test_hist_tools.py index 0d8d61d3f..fec8d00b0 100644 --- a/tests/test_hist_tools.py +++ b/tests/test_hist_tools.py @@ -265,3 +265,7 @@ def test_issue_333(): axis = hist.Bin("channel", "Channel b1", 50, 0, 2000) temp = np.arange(0, 2000, 40, dtype=np.int16) assert np.all(axis.index(temp) == np.arange(50) + 1) + +def test_issue_394(): + dummy = hist.Hist("Dummy" , hist.Cat("sample", "sample"), hist.Bin("dummy", "Number of events", 1, 0, 1)) + dummy.fill(sample="test", dummy=1, weight=0.5)