Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | | util.stanza: Support inclusion of <gone> URI from util.error object | Kim Alvefur | 2020-09-26 | 1 | -0/+5 | |
| | | ||||||
* | | util.stanza: Support getting 'by' from util.error object | Kim Alvefur | 2020-09-26 | 1 | -1/+2 | |
| | | ||||||
* | | util.error: Add well-known field 'extra' | Kim Alvefur | 2020-09-26 | 1 | -0/+8 | |
| | | | | | | | | | | A place for various extra fields and edge cases of the stanza error data model, e.g. the URI field of <gone> | |||||
* | | util.dataforms: Add support for validating (integer) ranges | Kim Alvefur | 2019-11-21 | 1 | -0/+9 | |
| | | ||||||
* | | util.interpolation: Add test for ~ when value is false (not just nil) | Matthew Wild | 2020-09-09 | 1 | -3/+7 | |
| | | ||||||
* | | util.interpolation: Add '~' as the opposite of '&' (render sub-block if falsy) | Matthew Wild | 2020-09-09 | 1 | -1/+11 | |
| | | | | | | | | One more magic character consumed! | |||||
* | | util.event: Add luacheck annotation to unused parameter in tests | Matthew Wild | 2020-09-03 | 1 | -1/+1 | |
| | | ||||||
* | | util.events: Add set_debug_hook() method | Matthew Wild | 2020-09-03 | 1 | -0/+38 | |
| | | | | | | | | | | | | Hook signature: ret = debug_hook(handler, event_name, event_data) | |||||
* | | util.jid: Add test coverage for XEP-0106: JID Escaping functions | Kim Alvefur | 2020-08-28 | 1 | -0/+50 | |
| | | ||||||
* | | util.dbuffer: Simplify test case | Kim Alvefur | 2020-08-24 | 1 | -3/+2 | |
| | | | | | | | | | | | | | | | | | | An earlier theory involved the bug being related to collapsing multiple items, so it exercised that too. Also correct the comment, it referred to the space in "hello world" in an earlier version before the test string was changed to "foobar", which was what was tested in a REPL | |||||
* | | util.dbuffer: Fix :sub() not working with partially-consumed chunks (thanks ↵ | Matthew Wild | 2020-08-24 | 1 | -1/+1 | |
| | | | | | | | | | | | | Zash for test case) This also appears to fix some bugs with chunk-encoded streams in net.http.parser. | |||||
* | | util.dbuffer: Add failing test case involving :sub after :discard | Kim Alvefur | 2020-08-24 | 1 | -0/+9 | |
| | | ||||||
* | | mod_external_services: XEP-0215: External Service Discovery | Kim Alvefur | 2020-07-18 | 2 | -0/+69 | |
| | | ||||||
* | | net.http.parser: Allow configuration of the chunk size fed to the parser | Matthew Wild | 2020-08-21 | 1 | -1/+3 | |
| | | ||||||
* | | net.http.parser: Switch tests so that CRLF conversion of input data is optional | Matthew Wild | 2020-08-21 | 1 | -7/+10 | |
| | | ||||||
* | | net.http.parser: Fix incorrect path in test | Matthew Wild | 2020-08-21 | 1 | -1/+1 | |
| | | ||||||
* | | net.http.parser: Add failing test for (large?) chunk-encoded responses | Matthew Wild | 2020-08-21 | 2 | -0/+27 | |
| | | ||||||
* | | util.dbuffer: Fix traceback when :collapse() is called on empty buffer | Matthew Wild | 2020-08-20 | 1 | -0/+12 | |
| | | ||||||
* | | util.dataforms: Add more XEP-0211 media element test coverage | Kim Alvefur | 2020-08-16 | 1 | -0/+28 | |
| | | ||||||
* | | util.dataforms: Convert media element sizes to avoid error on Lua 5.3 | Kim Alvefur | 2020-08-16 | 1 | -0/+15 | |
| | | | | | | | | | | | | | | | | The stanza API does not accept number values and threw an error due to the height and width attributes of the media element (XEP-0221). This part had no test coverage previously, explaining why it was not discovered until now. | |||||
* | | net.http.parser: Allow specifying sink for large request bodies | Kim Alvefur | 2020-08-01 | 1 | -3/+5 | |
| | | | | | | | | | | | | | | This enables uses such as saving uploaded files directly to a file on disk or streaming parsing of payloads. See #726 | |||||
* | | mod_server_contact_info: Add status-addresses field | Kim Alvefur | 2020-05-27 | 2 | -0/+4 | |
| | | | | | | | | XEP-0157 version 1.1.0 | |||||
* | | scansion/prosody.cfg: Fix typo | Kim Alvefur | 2020-07-09 | 1 | -1/+1 | |
| | | ||||||
* | | util.indexedbheap: Add failing test case for #1572 | Kim Alvefur | 2020-07-08 | 1 | -0/+15 | |
| | | | | | | | | | | This approximates what happens if you add a timer far in the future, then reschedule it to right now. | |||||
* | | util.dbuffer: If no bytes parameter passed to read, return remainder of ↵ | Matthew Wild | 2020-06-29 | 1 | -0/+15 | |
| | | | | | | | | frontmost chunk | |||||
* | | util.human.io: Add brief test of table generation | Kim Alvefur | 2020-06-28 | 1 | -0/+29 | |
| | | ||||||
* | | util.dbuffer: Don't use # operator in tests, Lua 5.1 doesn't support __len | Matthew Wild | 2020-06-28 | 1 | -1/+1 | |
| | | ||||||
* | | util.dbuffer: dynamic string buffer | Matthew Wild | 2020-06-26 | 1 | -0/+95 | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Similar to util.ringbuffer (and shares almost identical API). Differences: - size limit is optional and dynamic - does not allocate a fixed buffer of max_size bytes - focus on simply storing references to existing string objects where possible, avoiding unnecessary allocations - references are still stored in a ring buffer to enable use as a fast FIFO Optional second parameter to new() provides the number of ring buffer segments. On Lua 5.2 on my laptop, a segment is ~19 bytes. If the ring buffer fills up, the next write will compact all strings into a single item. | |||||
* | | util.ringbuffer: Fix accidentally committed test change (thanks buildbot) | Matthew Wild | 2020-06-25 | 1 | -1/+1 | |
| | | ||||||
* | | util.ringbuffer: Add some additional asserts to tests | Matthew Wild | 2020-06-24 | 1 | -4/+4 | |
| | | ||||||
* | | util.ringbuffer: Ensure unsigned chars are always returned from :byte() | Matthew Wild | 2020-06-24 | 1 | -0/+7 | |
| | | ||||||
* | | util.ringbuffer: Add test for :discard() | Matthew Wild | 2020-06-23 | 1 | -0/+11 | |
| | | ||||||
* | | scansion tests: Enable mod_muc_mam during tests (expect breakage) | Kim Alvefur | 2020-06-21 | 1 | -0/+4 | |
| | | ||||||
* | | MUC: Remove XEP-0091 Legacy Delayed Delivery from test | Kim Alvefur | 2020-06-21 | 1 | -1/+0 | |
| | | | | | | | | | | | | | | Long time Obsolete XEP. The element is apparently not included when mod_muc_mam is enabled, and deleting this seems like the sanity-preserving approach. | |||||
* | | storage tests: Add tests for archive queries before/after specific ids | Matthew Wild | 2020-06-12 | 1 | -5/+47 | |
| | | | | | | | | | | Also increased the size of the test data for easier debugging with more complex tests. | |||||
* | | util.promise: Add all_settled, which follows semantics of allSettled from ES2020 | Matthew Wild | 2020-06-08 | 1 | -0/+54 | |
| | | ||||||
* | | util.human.io: Fix right-alignment | Kim Alvefur | 2020-06-06 | 1 | -2/+4 | |
| | | ||||||
* | | util.ringbuffer: Add :sub() and :byte() methods equivalent to the string methods | Matthew Wild | 2020-06-04 | 1 | -0/+58 | |
| | | ||||||
* | | util.ringbuffer: Prevent creation of buffer with negative size | Kim Alvefur | 2020-06-04 | 1 | -0/+5 | |
| | | | | | | | | | | Previously this would have been (unsigned)-1 which is a large positive integer. | |||||
* | | util.ringbuffer: Prevent creation of zero-size buffer | Kim Alvefur | 2020-05-29 | 1 | -0/+5 | |
| | | ||||||
* | | util.ringbuffer: Add some initial tests | Kim Alvefur | 2020-05-29 | 1 | -0/+17 | |
| | | ||||||
* | | util.human.units: A library for formatting numbers with SI units | Kim Alvefur | 2019-01-04 | 1 | -0/+15 | |
| | | ||||||
* | | scansion: Add test for mod_server_contact_info / XEP-0157 | Kim Alvefur | 2020-05-27 | 2 | -1/+63 | |
| | | ||||||
* | | mod_storage_internal: Fix keeping old timestamp in archive map API | Kim Alvefur | 2020-05-15 | 1 | -3/+14 | |
| | | | | | | | | | | This led to a missing 'when' field on changed items, which would cause a traceack. | |||||
* | | mod_storage_internal: Implement key-value API | Kim Alvefur | 2020-05-11 | 1 | -0/+15 | |
| | | ||||||
* | | spec/storage: Reset build context of test stanza make comparisons easier | Kim Alvefur | 2020-05-11 | 1 | -1/+2 | |
| | | | | | | | | | | | | | | While building a stanza there's a .last_add field keeping track of where in the XML tree tags are being added. This field does not survive a roundtrip through preserialize / deserialize. :reset() removes this, which simplifes comparisons after such a roundtrip. | |||||
* | | spec/scansion/blocking: Don't send stanzas after disconnecting | Kim Alvefur | 2020-05-09 | 1 | -4/+4 | |
| | | | | | | | | | | | | | | Probably casued by mod_scansion_record catching the unavailable presence generated by Prosody on disconnect. See #1549 | |||||
* | | util.rsm: Test that Lua 5.3 floats are not encoded with decimal point | Kim Alvefur | 2020-04-23 | 1 | -0/+7 | |
| | | | | | | | | | | | | | | | | 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". | |||||
* | | util.rsm: Add tests | Kim Alvefur | 2020-04-23 | 1 | -0/+82 | |
| | | | | | | | | Based on examples from XEP-0059 | |||||
* | | MUC tests: Add missing 'affiliation' attribute | Matthew Wild | 2020-04-23 | 1 | -1/+1 | |
| | |