diff options
author | Joshua Haberman <jhaberman@gmail.com> | 2016-12-13 16:31:02 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-12-13 16:31:02 -0800 |
commit | 2ff42dcf2c99105e7b550bfaccb0a42b9721138c (patch) | |
tree | 416cb48efb61e4ed7aee52d503c0b3f23aec9267 /conformance/conformance_test.h | |
parent | f983302ca7051bd1364a6ea9218e21040e4a851b (diff) | |
download | protobuf-2ff42dcf2c99105e7b550bfaccb0a42b9721138c.tar.gz protobuf-2ff42dcf2c99105e7b550bfaccb0a42b9721138c.tar.bz2 protobuf-2ff42dcf2c99105e7b550bfaccb0a42b9721138c.zip |
Added conformance testing for binary primitive types. (#2491)
This is basic and more tests will be added over time.
Diffstat (limited to 'conformance/conformance_test.h')
-rw-r--r-- | conformance/conformance_test.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/conformance/conformance_test.h b/conformance/conformance_test.h index 2c5994b0..5f05a25b 100644 --- a/conformance/conformance_test.h +++ b/conformance/conformance_test.h @@ -175,9 +175,11 @@ class ConformanceTestSuite { ConformanceLevel level, const protobuf_test_messages::proto3::TestAllTypes& input, const string& equivalent_text_format); - void RunValidProtobufTest( - const string& test_name, - ConformanceLevel level, + void RunValidProtobufTest(const string& test_name, ConformanceLevel level, + const string& input_protobuf, + const string& equivalent_text_format); + void RunValidProtobufTestWithMessage( + const string& test_name, ConformanceLevel level, const protobuf_test_messages::proto3::TestAllTypes& input, const string& equivalent_text_format); @@ -199,6 +201,9 @@ class ConformanceTestSuite { const std::string& test_name, ConformanceLevel level); void TestPrematureEOFForType(google::protobuf::FieldDescriptor::Type type); + void TestValidDataForType( + google::protobuf::FieldDescriptor::Type, + std::vector<std::pair<std::string, std::string>> values); bool CheckSetEmpty(const set<string>& set_to_check, const std::string& write_to_file, const std::string& msg); ConformanceTestRunner* runner_; |