dbrgn / shtcx-rs

Platform agnostic Rust driver for the Sensirion SHTCx temperature/humidity sensors.
Apache License 2.0
13 stars 4 forks source link

Test improvements #4

Closed dbrgn closed 4 years ago

dbrgn commented 4 years ago

Increase test coverage.

This includes a commit that implements temperature-only and humidity-only measurements.

For this, the Measurement struct was split up into two types. Additionally, the raw values are now converted when measuring, not when requesting the converted values.

codecov[bot] commented 4 years ago

Codecov Report

Merging #4 into master will increase coverage by 4.63%. The diff coverage is 85.71%.

@@            Coverage Diff             @@
##           master       #4      +/-   ##
==========================================
+ Coverage   77.66%   82.29%   +4.63%     
==========================================
  Files           1        1              
  Lines         197       96     -101     
==========================================
- Hits          153       79      -74     
+ Misses         44       17      -27
Impacted Files Coverage Δ
src/lib.rs 82.29% <85.71%> (+4.63%) :arrow_up: