Resolve "testing libs compiled even without --with-gtest"

Merge request reports