Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Marcus Hoffmann
nettle
Commits
16be5ff6
Commit
16be5ff6
authored
Feb 11, 2003
by
Niels Möller
Browse files
(test_main): Added test for %( and
%). Rev: src/nettle/testsuite/sexp-format-test.c:1.7
parent
3fe07807
Changes
1
Hide whitespace changes
Inline
Side-by-side
testsuite/sexp-format-test.c
View file @
16be5ff6
...
...
@@ -106,6 +106,21 @@ test_main(void)
ASSERT
(
MEMEQ
(
buffer
.
size
,
buffer
.
contents
,
e
));
}
/* Literal parenthesis */
{
const
uint8_t
e
[]
=
")3:foo(3:bar"
;
nettle_buffer_init
(
&
buffer
);
ASSERT
(
sexp_format
(
&
buffer
,
"%)foo%(%s"
,
3
,
"bar"
)
==
strlen
(
e
));
ASSERT
(
sexp_format
(
NULL
,
"%)foo%(%s"
,
3
,
"bar"
)
==
strlen
(
e
));
ASSERT
(
buffer
.
size
==
strlen
(
e
));
ASSERT
(
MEMEQ
(
buffer
.
size
,
buffer
.
contents
,
e
));
}
#if HAVE_LIBGMP
{
mpz_t
x
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment