mirror of
https://github.com/Tencent/rapidjson.git
synced 2025-10-27 19:10:24 +01:00
Improve coverage for SchemaValidator:::AppendToken()
This commit is contained in:
@@ -960,6 +960,19 @@ TEST(SchemaValidator, AllOf_Nested) {
|
||||
INVALIDATE(s, "123", "", "allOf", "");
|
||||
}
|
||||
|
||||
TEST(SchemaValidator, EscapedPointer) {
|
||||
Document sd;
|
||||
sd.Parse(
|
||||
"{"
|
||||
" \"type\": \"object\","
|
||||
" \"properties\": {"
|
||||
" \"~/\": { \"type\": \"number\" }"
|
||||
" }"
|
||||
"}");
|
||||
SchemaDocument s(sd);
|
||||
INVALIDATE(s, "{\"~/\":true}", "/properties/~0~1", "type", "/~0~1");
|
||||
}
|
||||
|
||||
template <typename Allocator>
|
||||
static char* ReadFile(const char* filename, Allocator& allocator) {
|
||||
const char *paths[] = {
|
||||
|
||||
Reference in New Issue
Block a user