From 08fc46610768929c7ada06c0810da90b9a1eba74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Ka=CC=88fer?= Date: Tue, 3 Jun 2014 18:10:53 +0200 Subject: [PATCH] load stylesheet file for headless test --- test/headless.cpp | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/test/headless.cpp b/test/headless.cpp index af34f4e19..8c1dc3a26 100644 --- a/test/headless.cpp +++ b/test/headless.cpp @@ -1,9 +1,5 @@ -#include #include "gtest/gtest.h" - - - #include #include #include @@ -11,6 +7,11 @@ #include +#include +#include +#include + + namespace llmr { namespace platform { @@ -113,6 +114,13 @@ TEST(Headless, initialize) { map.resize(width, height); + std::ifstream stylefile("./style.min.js"); + ASSERT_TRUE(stylefile.good()); + std::stringstream stylejson; + stylejson << stylefile.rdbuf(); + + map.setStyleJSON(stylejson.str()); + timer.report("map resize"); // Run the loop. It will terminate when we don't have any further listeners.