karbassi / netatmo

A node.js module to hook into the netatmo API.
MIT License
57 stars 46 forks source link

Write tests #75

Open karbassi opened 2 years ago

karbassi commented 2 years ago

To bring this package up to standards, we need to have tests for each API call.

The API docs have definitions of what is required and optional and what is expected.

For example: https://dev.netatmo.com/apidocumentation/weather#getpublicdata

Name Type Required Default Description
lat_ne number Y latitude of the north east corner of the requested area. -85 <= lat_ne <= 85 and lat_ne>lat_sw
lon_ne number Y Longitude of the north east corner of the requested area. -180 <= lon_ne <= 180 and lon_ne>lon_sw
lat_sw number Y latitude of the south west corner of the requested area. -85 <= lat_sw <= 85
lon_sw number Y Longitude of the south west corner of the requested area. -180 <= lon_sw <= 180
required_data string N '' To filter stations based on relevant measurements you want (e.g. rain will only return stations with rain gauges). You can find all measurements available on the Thermostat page.
filter boolean N false True to exclude station with abnormal temperature measures.
karbassi commented 2 years ago

@floetenbaer is this something you can take on?

floetenbaer commented 2 years ago

@karbassi : uploaded new branch: feature/unit-test. What do you think about it?