clang-format: Update to match docs repo

Update the .clang-format file and run clang-format-6.0.
This .clang-format matches the example one in
https://github.com/openbmc/docs/blob/master/cpp-style-and-conventions.md#clang-formatting

Change-Id: Ia331c9a5b040e1a3c45a0ebf1b8d776d93b05ae5
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
diff --git a/test/test_ethernet_interface.cpp b/test/test_ethernet_interface.cpp
index 2181006..1b284a2 100644
--- a/test/test_ethernet_interface.cpp
+++ b/test/test_ethernet_interface.cpp
@@ -1,10 +1,7 @@
 #include "config_parser.hpp"
-#include "network_manager.hpp"
-#include "mock_syscall.hpp"
 #include "ipaddress.hpp"
-
-#include <gtest/gtest.h>
-#include <sdbusplus/bus.hpp>
+#include "mock_syscall.hpp"
+#include "network_manager.hpp"
 
 #include <arpa/inet.h>
 #include <net/if.h>
@@ -13,6 +10,9 @@
 
 #include <exception>
 #include <fstream>
+#include <sdbusplus/bus.hpp>
+
+#include <gtest/gtest.h>
 
 namespace phosphor
 {
@@ -21,116 +21,103 @@
 
 class TestEthernetInterface : public testing::Test
 {
-    public:
+  public:
+    sdbusplus::bus::bus bus;
+    Manager manager;
+    EthernetInterface interface;
+    std::string confDir;
+    TestEthernetInterface() :
+        bus(sdbusplus::bus::new_default()),
+        manager(bus, "/xyz/openbmc_test/network", "/tmp/"),
+        interface(bus, "/xyz/openbmc_test/network/test0", false, manager)
 
-        sdbusplus::bus::bus bus;
-        Manager manager;
-        EthernetInterface interface;
-        std::string confDir;
-        TestEthernetInterface()
-            : bus(sdbusplus::bus::new_default()),
-              manager(bus, "/xyz/openbmc_test/network", "/tmp/"),
-              interface(bus, "/xyz/openbmc_test/network/test0", false, manager)
+    {
+        setConfDir();
+    }
 
+    void setConfDir()
+    {
+        char tmp[] = "/tmp/EthernetInterface.XXXXXX";
+        confDir = mkdtemp(tmp);
+        manager.setConfDir(confDir);
+    }
+
+    ~TestEthernetInterface()
+    {
+        if (confDir != "")
         {
-            setConfDir();
+            fs::remove_all(confDir);
         }
+    }
 
-        void setConfDir()
+    int countIPObjects()
+    {
+        return interface.getAddresses().size();
+    }
+
+    bool isIPObjectExist(const std::string& ipaddress)
+    {
+        auto address = interface.getAddresses().find(ipaddress);
+        if (address == interface.getAddresses().end())
         {
-            char tmp[] = "/tmp/EthernetInterface.XXXXXX";
-            confDir = mkdtemp(tmp);
-            manager.setConfDir(confDir);
+            return false;
         }
+        return true;
+    }
 
-        ~TestEthernetInterface()
+    bool deleteIPObject(const std::string& ipaddress)
+    {
+        auto address = interface.getAddresses().find(ipaddress);
+        if (address == interface.getAddresses().end())
         {
-            if(confDir != "")
-            {
-                fs::remove_all(confDir);
-            }
+            return false;
         }
+        address->second->delete_();
+        return true;
+    }
 
+    std::string getObjectPath(const std::string& ipaddress, uint8_t subnetMask,
+                              const std::string& gateway)
+    {
+        IP::Protocol addressType = IP::Protocol::IPv4;
 
-        int countIPObjects()
+        return interface.generateObjectPath(addressType, ipaddress, subnetMask,
+                                            gateway);
+    }
+
+    void createIPObject(IP::Protocol addressType, const std::string& ipaddress,
+                        uint8_t subnetMask, const std::string& gateway)
+    {
+        interface.iP(addressType, ipaddress, subnetMask, gateway);
+    }
+
+    // Validates if the DNS entries have been correctly processed
+    void validateResolvFile(ServerList values)
+    {
+        // Check whether the entries has been written to resolv.conf
+        fs::path resolvFile = confDir;
+        resolvFile /= "resolv.conf";
+
+        // Passed in "value" is what is read from the config file
+        interface.writeDNSEntries(values, resolvFile);
+        std::string expectedServers =
+            "### Generated manually via dbus settings ###";
+        expectedServers +=
+            "nameserver 9.1.1.1nameserver 9.2.2.2nameserver 9.3.3.3";
+
+        std::string actualServers{};
+        std::fstream stream(resolvFile.string().c_str(), std::fstream::in);
+        for (std::string line; std::getline(stream, line);)
         {
-            return interface.getAddresses().size();
+            actualServers += line;
         }
-
-        bool isIPObjectExist(const std::string& ipaddress)
-        {
-            auto address = interface.getAddresses().find(ipaddress);
-            if (address == interface.getAddresses().end())
-            {
-                return false;
-            }
-            return true;
-
-        }
-
-        bool deleteIPObject(const std::string& ipaddress)
-        {
-            auto address = interface.getAddresses().find(ipaddress);
-            if (address == interface.getAddresses().end())
-            {
-                return false;
-            }
-            address->second->delete_();
-            return true;
-        }
-
-        std::string getObjectPath(const std::string& ipaddress,
-                                  uint8_t subnetMask,
-                                  const std::string& gateway)
-        {
-            IP::Protocol addressType = IP::Protocol::IPv4;
-
-            return interface.generateObjectPath(addressType,
-                                                ipaddress,
-                                                subnetMask,
-                                                gateway);
-        }
-
-        void createIPObject(IP::Protocol addressType,
-                            const std::string& ipaddress,
-                            uint8_t subnetMask,
-                            const std::string& gateway)
-        {
-            interface.iP(addressType,
-                         ipaddress,
-                         subnetMask,
-                         gateway
-                        );
-
-        }
-
-        // Validates if the DNS entries have been correctly processed
-        void validateResolvFile(ServerList values)
-        {
-            // Check whether the entries has been written to resolv.conf
-            fs::path resolvFile = confDir;
-            resolvFile /= "resolv.conf";
-
-            // Passed in "value" is what is read from the config file
-            interface.writeDNSEntries(values, resolvFile);
-            std::string expectedServers = "### Generated manually via dbus settings ###";
-            expectedServers +=
-                "nameserver 9.1.1.1nameserver 9.2.2.2nameserver 9.3.3.3";
-
-            std::string actualServers{};
-            std::fstream stream(resolvFile.string().c_str(), std::fstream::in);
-            for (std::string line; std::getline(stream, line);)
-            {
-                actualServers += line;
-            }
-            EXPECT_EQ(expectedServers , actualServers);
-        }
+        EXPECT_EQ(expectedServers, actualServers);
+    }
 };
 
 TEST_F(TestEthernetInterface, NoIPaddress)
 {
     EXPECT_EQ(countIPObjects(), 0);
-
 }
 
 TEST_F(TestEthernetInterface, AddIPAddress)
@@ -138,7 +125,6 @@
     IP::Protocol addressType = IP::Protocol::IPv4;
     createIPObject(addressType, "10.10.10.10", 16, "10.10.10.1");
     EXPECT_EQ(true, isIPObjectExist("10.10.10.10"));
-
 }
 
 TEST_F(TestEthernetInterface, AddMultipleAddress)
@@ -148,7 +134,6 @@
     createIPObject(addressType, "20.20.20.20", 16, "20.20.20.1");
     EXPECT_EQ(true, isIPObjectExist("10.10.10.10"));
     EXPECT_EQ(true, isIPObjectExist("20.20.20.20"));
-
 }
 
 TEST_F(TestEthernetInterface, DeleteIPAddress)
@@ -159,7 +144,6 @@
     deleteIPObject("10.10.10.10");
     EXPECT_EQ(false, isIPObjectExist("10.10.10.10"));
     EXPECT_EQ(true, isIPObjectExist("20.20.20.20"));
-
 }
 
 TEST_F(TestEthernetInterface, DeleteInvalidIPAddress)
@@ -180,19 +164,15 @@
     hashString += std::to_string(prefix);
     hashString += gateway;
 
-
-    hexId << std::hex << ((std::hash<std::string> {}(
-                               hashString)) & 0xFFFFFFFF);
+    hexId << std::hex << ((std::hash<std::string>{}(hashString)) & 0xFFFFFFFF);
     expectedObjectPath += hexId.str();
 
-    EXPECT_EQ(expectedObjectPath, getObjectPath(ipaddress,
-                                                prefix,
-                                                gateway));
+    EXPECT_EQ(expectedObjectPath, getObjectPath(ipaddress, prefix, gateway));
 }
 
 TEST_F(TestEthernetInterface, addNameServers)
 {
-    ServerList servers = {"9.1.1.1","9.2.2.2","9.3.3.3"};
+    ServerList servers = {"9.1.1.1", "9.2.2.2", "9.3.3.3"};
     interface.nameservers(servers);
     fs::path filePath = confDir;
     filePath /= "00-bmc-test0.network";
@@ -200,14 +180,14 @@
     config::ReturnCode rc = config::ReturnCode::SUCCESS;
     config::ValueList values;
     std::tie(rc, values) = parser.getValues("Network", "DNS");
-    EXPECT_EQ(servers , values);
+    EXPECT_EQ(servers, values);
 
     validateResolvFile(values);
 }
 
 TEST_F(TestEthernetInterface, addNTPServers)
 {
-    ServerList servers = {"10.1.1.1","10.2.2.2","10.3.3.3"};
+    ServerList servers = {"10.1.1.1", "10.2.2.2", "10.3.3.3"};
     interface.nTPServers(servers);
     fs::path filePath = confDir;
     filePath /= "00-bmc-test0.network";
@@ -215,8 +195,8 @@
     config::ReturnCode rc = config::ReturnCode::SUCCESS;
     config::ValueList values;
     std::tie(rc, values) = parser.getValues("Network", "NTP");
-    EXPECT_EQ(servers , values);
+    EXPECT_EQ(servers, values);
 }
 
-}// namespce network
-}// namespace phosphor
+} // namespace network
+} // namespace phosphor