Commit graph

18 commits

Author SHA1 Message Date
1110288d84 Migrate from testify to nalgeon/be testing library
- Replace all testify/assert and testify/require with be library
- Update go.mod to use be v0.3.0 instead of testify
- Simplify test assertions using be.Equal, be.Err, and be.True
- Refactor append_test, entry_test, meta_test, log_test, and formatter tests
2026-02-13 16:02:38 -06:00
6095c2497e Add support for mixed-level nested keys with dot/blank handling
- Handle @parent:child and @parent🧒grandchild coexistence
- Use '.' key for parent values when nested children exist
- Add comprehensive test cases for double-nested scenarios
- Support both '.' and '' as special keys for parent values
2026-02-12 10:41:35 -06:00
4fc1c623a0 Implement full support for nested fields in Meta and Entry marshalling
This commit completes the implementation of nested field support.
- :
    -  now correctly handles  and  by recursively flattening them into  format.
    - Introduced  for recursive map marshalling.
    - Refactored  for cleaner buffer writing.
- : Added comprehensive test cases for nested JSON, nested maps, double-nested maps, and nested keys within JSON to ensure correct marshalling and unmarshalling.
- : Updated tests to reflect the new nil handling and removed redundant JSON object test.

This allows for more flexible and structured data representation within log entries.
2026-02-10 18:15:07 -06:00
c4e864afa5 Add support for nested fields in log entries and JSON marshalling
This commit introduces the ability to handle nested fields within log entries.
The  file has been updated with a  function
that transforms flat keys with a : delimiter (e.g., obj:foo) into nested
JSON objects (e.g., ).

The  file includes new test cases to verify that:
- Nested fields are correctly unmarshalled from string representations.
- Nested fields are correctly marshalled into JSON objects.

This enhancement allows for more structured and organized metadata within log entries.
2026-02-10 16:13:39 -06:00
fbcec20221 🐛 Fix entry_test.go assertions for new id field 2026-02-10 15:43:23 -06:00
820a2de269 ♻️ Get rid of PartialEntry 2024-03-10 15:26:00 -05:00
5b8e4696ea Only add newline to file when needed 2024-03-09 15:38:34 -06:00
c1b1ceb283 Use ParseDate in Entry 2024-02-25 13:39:12 -06:00
cc9e8f6167 Drop command 2024-02-11 13:50:27 -06:00
16a0a9d20b Special handling of json field 2024-01-30 23:40:47 -06:00
0da5efcafe Entry implements json.Unmarshaler 2024-01-29 22:07:18 -06:00
eff9a454f9 🧪 Test json.Unmarshaler implementation for Entry 2024-01-28 22:02:57 -06:00
f3bf89b09e Entry implements json.Marshaler 2024-01-28 19:41:30 -06:00
7e1c51d698 🧪 Test json.Marshaler implementation for Entry 2024-01-28 19:23:51 -06:00
c45acd57c4 Entry implements TextUnmarshaler 2024-01-28 17:39:42 -06:00
2d68691408 ♻️ Use defined errors 2024-01-28 12:41:55 -06:00
5b60305de7 🧪 Test TextUnmarshaler implementation for Entry 2024-01-28 08:56:34 -06:00
e8fb298ea5 Entry with TextMarshaler 2024-01-28 01:13:25 -06:00