diff options
author | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2015-05-07 22:35:18 -0300 |
---|---|---|
committer | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2015-05-07 22:35:18 -0300 |
commit | b24efa3885637d953892ccf718662aa693eaa879 (patch) | |
tree | 76e5f074021f59194535a79ea348f711c8db68cd /tests/check_source_parser.c | |
parent | 28b02d920aa9347f25bc28f5989919174d9f60a9 (diff) | |
download | blogc-b24efa3885637d953892ccf718662aa693eaa879.tar.gz blogc-b24efa3885637d953892ccf718662aa693eaa879.tar.bz2 blogc-b24efa3885637d953892ccf718662aa693eaa879.zip |
content-parser: more random stuff
Diffstat (limited to 'tests/check_source_parser.c')
-rw-r--r-- | tests/check_source_parser.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/check_source_parser.c b/tests/check_source_parser.c index 0838f41..c779ed3 100644 --- a/tests/check_source_parser.c +++ b/tests/check_source_parser.c @@ -34,10 +34,13 @@ test_source_parse(void **state) b_trie_t *source = blogc_source_parse(a, strlen(a), &err); assert_null(err); assert_non_null(source); - assert_int_equal(b_trie_size(source), 3); + assert_int_equal(b_trie_size(source), 4); assert_string_equal(b_trie_lookup(source, "VAR1"), "asd asd"); assert_string_equal(b_trie_lookup(source, "VAR2"), "123chunda"); assert_string_equal(b_trie_lookup(source, "CONTENT"), + "<h1>This is a test</h1>\n" + "<p>bola</p>\n"); + assert_string_equal(b_trie_lookup(source, "RAW_CONTENT"), "# This is a test\n" "\n" "bola\n"); @@ -61,10 +64,13 @@ test_source_parse_with_spaces(void **state) b_trie_t *source = blogc_source_parse(a, strlen(a), &err); assert_null(err); assert_non_null(source); - assert_int_equal(b_trie_size(source), 3); + assert_int_equal(b_trie_size(source), 4); assert_string_equal(b_trie_lookup(source, "VAR1"), "chunda"); assert_string_equal(b_trie_lookup(source, "BOLA"), "guda"); assert_string_equal(b_trie_lookup(source, "CONTENT"), + "<h1>This is a test</h1>\n" + "<p>bola</p>\n"); + assert_string_equal(b_trie_lookup(source, "RAW_CONTENT"), "# This is a test\n" "\n" "bola\n"); |