#define EV_STR_IMPLEMENTATION #include "ev_str.h" #include #include int main(void) { evstring heap_str = evstring_new("Heap 'Hello, World!'"); assert(heap_str != NULL); evstring_error_t res = evstring_push(&heap_str, "%.05f", 1.0f); assert(res == EV_STR_ERR_NONE); assert(evstring_getLength(heap_str) == 27); assert(strcmp(heap_str, "Heap 'Hello, World!'1.00000") == 0); res = evstring_push(&heap_str, "Something"); assert(res == EV_STR_ERR_NONE); assert(evstring_getLength(heap_str) == 36); assert(strcmp(heap_str, "Heap 'Hello, World!'1.00000Something") == 0); evstring_free(heap_str); return 0; }