Commit graph

3 commits

Author SHA1 Message Date
Kim Alvefur
55fb091536 util.rsm: Increase test coverage
Test all fields in both directions in order to catch #1642
2021-03-06 18:22:52 +01:00
Kim Alvefur
67372d19bd util.rsm: Test that Lua 5.3 floats are not encoded with decimal point
The 'max' 'count' and 'index' fields are integers and should be encoded
as such on the wire.

Care needs to be taken because tostring(1.0) in Lua 5.3+ returns to "1.0"
while in previous Lua versions it would return "1".
2020-04-23 18:17:54 +02:00
Kim Alvefur
da2a13287e util.rsm: Add tests
Based on examples from XEP-0059
2020-04-23 18:05:00 +02:00