whatyouhide / stream_data

Data generation and property-based testing for Elixir. 🔮
https://hexdocs.pm/stream_data
864 stars 66 forks source link

Add some properties for the Enum module #175

Closed sabiwara closed 2 years ago

sabiwara commented 2 years ago

This PR is adding some property-based tests for some of the Enum functions that had some bugs.

Since the implementation is often duplicated for lists, ranges and reduce-based enums like stream, a nice thing to test is that a function works the same on:

This can catch inconsistencies and bugs, and we can easily add more coverage.

coveralls commented 2 years ago

Pull Request Test Coverage Report for Build 1e89b558018333261d3853aa5248d5eef355a0bf-PR-175


Files with Coverage Reduction New Missed Lines %
lib/stream_data.ex 6 93.02%
<!-- Total: 6 -->
Totals Coverage Status
Change from base Build 495e162a5d442e0827d09244a6f8efb593f31618: -1.5%
Covered Lines: 362
Relevant Lines: 388

💛 - Coveralls
whatyouhide commented 2 years ago

Fantastic @sabiwara ❤️