From 771c8ecc2f242a7dd8f45ebd91fd253ba37a2a65 Mon Sep 17 00:00:00 2001 From: "arseny.kapoulkine" Date: Sun, 29 Aug 2010 15:41:16 +0000 Subject: tests: Added more XPath tests git-svn-id: http://pugixml.googlecode.com/svn/trunk@683 99668b35-9821-0410-8761-19e4c4f06640 --- tests/test_xpath_parse.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'tests/test_xpath_parse.cpp') diff --git a/tests/test_xpath_parse.cpp b/tests/test_xpath_parse.cpp index f996b24..aa148be 100644 --- a/tests/test_xpath_parse.cpp +++ b/tests/test_xpath_parse.cpp @@ -291,4 +291,15 @@ TEST(xpath_parse_out_of_memory_string_to_number) CHECK_XPATH_FAIL(STR("0.11111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111")); } +TEST(xpath_parse_qname_error) +{ + CHECK_XPATH_FAIL(STR("foo: bar")); + CHECK_XPATH_FAIL(STR("foo :bar")); + CHECK_XPATH_FAIL(STR("foo: *")); + CHECK_XPATH_FAIL(STR("foo :*")); + CHECK_XPATH_FAIL(STR(":*")); + CHECK_XPATH_FAIL(STR(":bar")); + CHECK_XPATH_FAIL(STR(":")); +} + #endif -- cgit v1.2.3