fixed gtest linking
now use unique_ptrs