Skip to content

Commit

Permalink
update README
Browse files Browse the repository at this point in the history
  • Loading branch information
sheenacodes authored and laurigates committed Sep 15, 2023
1 parent 70e8509 commit c4c997e
Showing 1 changed file with 4 additions and 23 deletions.
27 changes: 4 additions & 23 deletions tests/test_digita_sensornode.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,28 +9,6 @@
}
]

expected_device = {
"url": "http://devreg:8000/api/v1/devices/70B3D57050011422/",
"device_id": "70B3D57050011422",
"type": "http://devreg:8000/api/v1/device-types/1/",
"name": "Digital Matter SensorNode 70B3D57050011422",
"pseudonym": "",
"description": "",
"created_at": "2023-06-08T12:18:28.816461+03:00",
"modified_at": "2023-06-08T12:18:28.816469+03:00",
"equipment_condition": "AC",
"last_active_at": None,
"current_location": None,
"sensor_config": None,
"unit_of_measurement": "",
"measurement_resolution": None,
"quality_indicator": "RE",
"owner": "http://devreg:8000/api/v1/users/1/",
"parser_module": "fvhiot.parsers.sensornode",
"maintenance_log_set": [],
"installation_image_set": [],
}


def test_parsed_data_from_kafka():
# Define server with port
Expand Down Expand Up @@ -58,5 +36,8 @@ def test_parsed_data_from_kafka():

assert parsed_msg["data"] == expected_data, "parsed data is correct"
assert (
parsed_msg["device"] == expected_device
parsed_msg["device"]["device_id"] == "70B3D57050011422"
), "retreived device metadata is correct"
assert (
parsed_msg["device"]["parser_module"] == "fvhiot.parsers.sensornode"
), "retreived device metadata is correct"

0 comments on commit c4c997e

Please sign in to comment.