static handler: transition to generic file handler

The static layout image handler simply writes the bytes into an expected
location and the verification mechanism is responsible for doing things
with the file there.  Therefore, use a file handler.

Change-Id: I97128fb04df640fe682c77ef7ee278c61293748f
Signed-off-by: Patrick Venture <venture@google.com>
diff --git a/test/Makefile.am b/test/Makefile.am
index f5bf4de..d7ca5a0 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -18,7 +18,7 @@
 	firmware_writemeta_unittest \
 	firmware_close_unittest \
 	firmware_delete_unittest \
-	static_handler_unittest
+	file_handler_unittest
 
 TESTS = $(check_PROGRAMS)
 
@@ -46,5 +46,5 @@
 firmware_delete_unittest_SOURCES = firmware_delete_unittest.cpp
 firmware_delete_unittest_LDADD = $(top_builddir)/firmware_handler.o
 
-static_handler_unittest_SOURCES = static_handler_unittest.cpp
-static_handler_unittest_LDADD = $(top_builddir)/static_handler.o
+file_handler_unittest_SOURCES = file_handler_unittest.cpp
+file_handler_unittest_LDADD = $(top_builddir)/file_handler.o
diff --git a/test/static_handler_unittest.cpp b/test/file_handler_unittest.cpp
similarity index 80%
rename from test/static_handler_unittest.cpp
rename to test/file_handler_unittest.cpp
index 4fda33d..26a490d 100644
--- a/test/static_handler_unittest.cpp
+++ b/test/file_handler_unittest.cpp
@@ -1,4 +1,4 @@
-#include "static_handler.hpp"
+#include "file_handler.hpp"
 
 #include <cstdint>
 #include <cstdio>
@@ -12,7 +12,7 @@
 
 static constexpr auto TESTPATH = "test.output";
 
-class StaticHandlerOpenTest : public ::testing::Test
+class FileHandlerOpenTest : public ::testing::Test
 {
   protected:
     void TearDown() override
@@ -21,23 +21,23 @@
     }
 };
 
-TEST_F(StaticHandlerOpenTest, VerifyItIsHappy)
+TEST_F(FileHandlerOpenTest, VerifyItIsHappy)
 {
     /* Opening a fail may create it? */
 
-    StaticLayoutHandler handler(TESTPATH);
+    FileHandler handler(TESTPATH);
     EXPECT_TRUE(handler.open(""));
 
     /* Calling open twice fails the second time. */
     EXPECT_FALSE(handler.open(""));
 }
 
-TEST_F(StaticHandlerOpenTest, VerifyWriteDataWrites)
+TEST_F(FileHandlerOpenTest, VerifyWriteDataWrites)
 {
     /* Verify writing bytes writes them... flushing data can be an issue here,
      * so we close first.
      */
-    StaticLayoutHandler handler(TESTPATH);
+    FileHandler handler(TESTPATH);
     EXPECT_TRUE(handler.open(""));
 
     std::vector<std::uint8_t> bytes = {0x01, 0x02};