aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_env.c
AgeCommit message (Collapse)AuthorFilesLines
2021-03-08WIP: Make serd_env_expand() always return a node if it is not relativeDavid Robillard1-30/+161
The old interface was potentially faster, because it avoided unnecessary copies, but was annoying to use and problematic because nodes that don't need expansion were indistinguishable from nodes that failed to expand (like those that use undefined namespace prefixes). In the grand scheme of things, the potential performance improvement isn't worth it, and unexpected unexpanded nodes causes deep nightmarish problems, so just make serd_env_expand() copy the input if it doesn't need expansion to make the API simpler and safer.
2021-03-08Clean up Env tests and behaviourDavid Robillard1-62/+178
2021-03-08Make const Env functions tolerant of NULLDavid Robillard1-0/+4
This is convenient in places where you don't necessarily need an Env, since in this case these methods work the same as if with an empty Env.
2021-03-08Clean up env testDavid Robillard1-4/+4
2021-03-08Add serd_env_copy() and serd_env_equals()David Robillard1-0/+23
2021-03-08Replace multiple stream callbacks with SerdEventDavid Robillard1-10/+14
This makes plumbing easier since everything goes through the same "stream" and only one callback is required to handling everything. It's also more easily extensible in case more event types need to be added in the future.
2021-03-08Simplify SerdEnv APIDavid Robillard1-32/+28
2021-03-07Simplify node construction APIDavid Robillard1-21/+26
2021-03-07Simplify URI API and implementationDavid Robillard1-0/+3
2021-03-07Make nodes opaqueDavid Robillard1-32/+37
2021-03-07Remove "get" from accessor namesDavid Robillard1-3/+3
2021-03-07Rename SerdChunk to SerdStringViewDavid Robillard1-2/+2
2021-03-07Use char* for strings in public APIDavid Robillard1-16/+11
The constant casting just makes user code a mess, for no benefit.
2021-01-02Use email address instead of website for attributionDavid Robillard1-1/+1
2020-12-31Format all code with clang-formatDavid Robillard1-46/+48
2020-11-13Allow setting the base URI of an Env to NULLDavid Robillard1-1/+6
2020-11-09Rename unit tests to start with a consistent prefixDavid Robillard1-0/+95