Fix memory leak on add function
Add test sorted liste