mirror of
https://github.com/RPCS3/yaml-cpp.git
synced 2026-07-21 03:05:22 -04:00
Small readability improvements in Parser
Also add a test for a parser with no data
This commit is contained in:
committed by
Jesse Beder
parent
72f699f5ce
commit
5b3e30bfe9
@@ -0,0 +1,16 @@
|
||||
#include "yaml-cpp/parser.h"
|
||||
#include "mock_event_handler.h"
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
using YAML::Parser;
|
||||
using YAML::MockEventHandler;
|
||||
using ::testing::StrictMock;
|
||||
|
||||
TEST(ParserTest, Empty) {
|
||||
Parser parser;
|
||||
|
||||
EXPECT_FALSE(parser);
|
||||
|
||||
StrictMock<MockEventHandler> handler;
|
||||
EXPECT_FALSE(parser.HandleNextDocument(handler));
|
||||
}
|
||||
Reference in New Issue
Block a user