aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorThomas White <taw@bitwiz.org.uk>2012-08-14 23:58:16 +0200
committerThomas White <taw@bitwiz.org.uk>2012-08-14 23:58:16 +0200
commit3d0d122d46ff38c47adbe3d4960440aaefc5705c (patch)
tree29c451423a03d7b5b1520e0ced6ce9652166fed4 /tests
parent2fd37a95bd5fe109a62917eca483b36a18a74777 (diff)
First bits of StoryCode parser
Diffstat (limited to 'tests')
-rw-r--r--tests/storycode_test.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/storycode_test.c b/tests/storycode_test.c
index 4ff4977..4ffc08c 100644
--- a/tests/storycode_test.c
+++ b/tests/storycode_test.c
@@ -32,6 +32,19 @@
int main(int argc, char *argv[])
{
+ SCBlockList *bl;
+ SCBlockListIterator *iter;
+ char *b;
+
+ bl = sc_find_blocks("\\bg{wibble \\f{wobble}}\\bg{rwawr}Wobble", "bg");
+
+ for ( b = sc_block_list_first(bl, &iter);
+ b != NULL;
+ b = sc_block_list_next(bl, iter) )
+ {
+ printf("'%s'\n", b);
+ }
+ sc_block_list_free(bl);
return 0;
}