Skip to content

Commit

Permalink
slight refactor of test_metrics.py
Browse files Browse the repository at this point in the history
Signed-off-by: alindima <alindima@amazon.com>
  • Loading branch information
alindima committed Jul 8, 2021
1 parent c339167 commit 86340cb
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions tests/integration_tests/functional/test_metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

import datetime
import os
import json
import math
import platform
import host_tools.logging as log_tools
Expand All @@ -27,8 +26,7 @@ def test_flush_metrics(test_microvm_with_api):

microvm.start()

res = metrics_fifo.sequential_reader(1)
metrics = json.loads(res[0])
metrics = microvm.flush_metrics(metrics_fifo)

exp_keys = [
'utc_timestamp_ms',
Expand Down Expand Up @@ -64,5 +62,3 @@ def test_flush_metrics(test_microvm_with_api):
# Epoch.Regression test for:
# https://github.com/firecracker-microvm/firecracker/issues/2639
assert abs(utc_timestamp_ms - metrics['utc_timestamp_ms']) < 1000

microvm.flush_metrics(metrics_fifo)

0 comments on commit 86340cb

Please sign in to comment.