face: Make default transport configurable

This commit also removes support for the ndnd-tlv-0.7
protocol's default socket location from UnixTransport.

Test HOME environment changing has also been centralized
into a single fixture (util/test-home-environment-fixture.hpp)

refs #2189

Change-Id: Iac1a6c88d7a2d9fcfb91a20356ac21b75daf7d17
diff --git a/tests/unit-tests/security/identity-fixture.cpp b/tests/unit-tests/security/identity-fixture.cpp
index 04589bc..38c85a8 100644
--- a/tests/unit-tests/security/identity-fixture.cpp
+++ b/tests/unit-tests/security/identity-fixture.cpp
@@ -20,20 +20,18 @@
  */
 
 #include "security/key-chain.hpp"
-
+#include "../util/test-home-environment-fixture.hpp"
 #include "boost-test.hpp"
 
 namespace ndn {
 namespace security {
 
-class IdentityFixture
+class IdentityFixture : public util::TestHomeEnvironmentFixture
 {
 public:
   IdentityFixture()
   {
     // initialize KeyChain from TEST_HOME
-    if (std::getenv("TEST_HOME"))
-      m_HOME = std::getenv("TEST_HOME");
     setenv("TEST_HOME", "tests/unit-tests/security/config-file-home", 1);
 
     KeyChain keyChain("sqlite3", "file");
@@ -71,11 +69,6 @@
     // XXX This has no effect if oldDefaultIdentity doesn't exist.
     //     newIdentity would be kept as default.
     keyChain.deleteIdentity(m_newIdentity);
-
-    if (!m_HOME.empty())
-      setenv("TEST_HOME", m_HOME.c_str(), 1);
-    else
-      unsetenv("TEST_HOME");
   }
 
 private: