Skip to content

Conversation

@ariel-anieli
Copy link

Hello maintainers,

This is my first ever contribution to the project; your feedback is much appreciated.

1c5733e introduced system_time_to_universal_time/2 for backward compatibility.

The minimum OTP version is now 24; calendar:system_time_to_universal_time/2 was introduced in OTP 21.

Thank you,

1c5733e ("Implement SPoRA, a novel consensus mechanism") introduced
system_time_to_universal_time/2 for backward compatibility.

The minimum OTP version is now 24; calendar:system_time_to_universal_time/2
was introduced in OTP 21.

Link: https://www.erlang.org/doc/apps/stdlib/calendar.html#system_time_to_universal_time/2
Signed-off-by: Ariel Otilibili <[email protected]>
@JamesPiechota
Copy link
Collaborator

Thanks @ariel-anieli ! Since that change is in a pretty sensitive area of the code, it would be worth having a small unit test in place to confirm no change in behavior. I suspect that codepath is already covered by some of the higher order tests, but having one specifically for the time function would give me more peace of mind.

Some notes about the arweave tests:

  • We use eunit but the majority of our tests are not actually unit tests - most are actually integration tests, we just use the eunit framework and utilities for test registration and assertions.
  • you can run all the tests with ./bin/test or limit the test run to specific module with ./bin/test module_name

@ariel-anieli
Copy link
Author

Thanks @ariel-anieli ! Since that change is in a pretty sensitive area of the code, it would be worth having a small unit test in place to confirm no change in behavior. I suspect that codepath is already covered by some of the higher order tests, but having one specifically for the time function would give me more peace of mind.

Some notes about the arweave tests:

* We use `eunit` but the majority of our tests are not actually unit tests - most are actually integration tests, we just use the `eunit` framework and utilities for test registration and assertions.

* you can run all the tests with `./bin/test` or limit the test run to specific module with `./bin/test module_name`

Thanks for the hints, @JamesPiechota; I'll look into them.

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.

2 participants