File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -1116,8 +1116,13 @@ def test_pulse_collection_consumption(
11161116 pulse_update_3 = fixed_this_hour + td (hours = 0 , minutes = 0 , seconds = 30 )
11171117 tst_consumption .update_pulse_counter (2500 , 0 , pulse_update_3 )
11181118 assert not tst_consumption .log_rollover
1119+ # Collected pulses last hour:
11191120 assert tst_consumption .collected_pulses (
1120- test_timestamp , is_consumption = True
1121+ fixed_this_hour , is_consumption = True
1122+ ) == (2500 , pulse_update_3 )
1123+ # Collected pulses last day:
1124+ assert tst_consumption .collected_pulses (
1125+ fixed_this_hour - td (hours = 24 ), is_consumption = True
11211126 ) == (2500 + 1111 + 1000 + 750 , pulse_update_3 )
11221127 pulse_update_4 = fixed_this_hour + td (hours = 1 , minutes = 1 , seconds = 3 )
11231128 tst_consumption .update_pulse_counter (45 , 0 , pulse_update_4 )
You can’t perform that action at this time.
0 commit comments