2016-03-03 19:53:58 +01:00
|
|
|
|
2016-02-09 19:08:29 +01:00
|
|
|
#include "catch.hpp"
|
|
|
|
#include <mapnik/enumeration.hpp>
|
2016-02-16 21:30:40 +01:00
|
|
|
#include <mapnik/symbolizer_enumerations.hpp>
|
2016-02-09 19:08:29 +01:00
|
|
|
#include <sstream>
|
|
|
|
|
|
|
|
TEST_CASE("enumeration") {
|
|
|
|
|
2016-02-16 21:30:40 +01:00
|
|
|
mapnik::line_cap_e e(mapnik::ROUND_CAP);
|
|
|
|
CHECK( e.as_string() == "round" );
|
|
|
|
// note: test the << operator, which calls `as_string` internally
|
|
|
|
// is not used in mapnik, but kept for back compat
|
2016-02-09 19:08:29 +01:00
|
|
|
std::stringstream s;
|
|
|
|
s << e;
|
2016-02-16 21:30:40 +01:00
|
|
|
CHECK( s.str() == "round" );
|
2016-02-09 19:08:29 +01:00
|
|
|
|
2017-05-05 13:02:01 +02:00
|
|
|
}
|