mirror of
https://github.com/qpdf/qpdf.git
synced 2024-12-22 19:08:59 +00:00
Add another string parsing test
This commit is contained in:
parent
1ecc6bb29e
commit
9fc02e2f91
@ -3344,12 +3344,16 @@ test_95(QPDF& pdf, char const* arg2)
|
|||||||
static void
|
static void
|
||||||
test_96(QPDF& pdf, char const* arg2)
|
test_96(QPDF& pdf, char const* arg2)
|
||||||
{
|
{
|
||||||
// Test edge cases with quoted characters
|
// Test edge cases with quoted characters and string parsing.
|
||||||
|
|
||||||
auto s = R"((\48\418\121\4))"_qpdf;
|
auto s = R"((\48\418\121\4))"_qpdf;
|
||||||
assert(s.unparseBinary() == "<043821385104>");
|
assert(s.unparseBinary() == "<043821385104>");
|
||||||
s = R"((\48\418\121\41))"_qpdf;
|
s = R"((\48\418\121\41))"_qpdf;
|
||||||
assert(s.unparseBinary() == "<043821385121>");
|
assert(s.unparseBinary() == "<043821385121>");
|
||||||
|
s = R"(<a>)"_qpdf;
|
||||||
|
assert(s.unparseBinary() == "<a0>");
|
||||||
|
s = R"(<abc>)"_qpdf;
|
||||||
|
assert(s.unparseBinary() == "<abc0>");
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user