The function maps:to_list/1 documentation states that it returns key-value pairs in an arbitrary order.
However, some tests assume a specific order and hard-code the resulting JSON with a definite order.
This causes the tests to fail when the order is different.
When I tried OTP27, the eunit tests failed as follows.
The function
maps:to_list/1
documentation states that it returns key-value pairs in an arbitrary order. However, some tests assume a specific order and hard-code the resulting JSON with a definite order. This causes the tests to fail when the order is different.When I tried OTP27, the eunit tests failed as follows.
Test code (one example):
Result:
I'm sorry I don't know what is the best way to fix it, so I wrote this issue instead of writing a pull request.