Skip to content

Conversation

@mkorszun
Copy link
Contributor

Summary of changes

WHY

Introduce property based tests in order to:

  • increase correctness of timex public api by discovering corner cases earlier
  • reduce number of example based tests, which will not be able to cover all scenarios and edge cases anyway

What

  • Use StreamData as a property based test framework
  • Introduce a couple of sample property tests. We can not really add property tests for all the public functions anyway. It will be a longer process and we would like to start it with this PR.

Checklist

  • New functions have typespecs, changed functions were updated
  • Same for documentation, including moduledocs
  • Tests were added or updated to cover changes
  • Commits were squashed into a single coherent commit

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

6 similar comments
@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

@coveralls
Copy link

coveralls commented Oct 30, 2018

Coverage Status

Coverage increased (+1.3%) to 73.09% when pulling e3576d8 on vorce:property_based_tests into 04dc72b on bitwalker:master.

@coveralls
Copy link

Coverage Status

Coverage increased (+1.7%) to 72.502% when pulling 4068c84 on vorce:property_based_tests into 933588a on bitwalker:master.

|> StreamData.map(&Timex.to_datetime/1)
end

def date_time_generator(:tupple) do
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I may just be missing something, but why :tupple and not :tuple?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ckhrysze typo :( - thanks for the feedback 👍

@vorce vorce force-pushed the property_based_tests branch from 4068c84 to e3576d8 Compare June 27, 2019 17:47
@bitwalker bitwalker merged commit 32018e5 into bitwalker:master Jun 27, 2019
@vorce vorce deleted the property_based_tests branch June 28, 2019 04:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants