Debian Codegraph @

doc/tutorial_src/stream_tests0.c

raw symbols SCIP
1 #include <cgreen/cgreen.h>
2 #include <cgreen/mocks.h>
3
4 char *read_paragraph(int (*read)(void *), void *stream);
5
6 static int empty_stream(void *stream) {
7 return EOF;
8 }
9
10 Describe(ParagraphReader);
11 BeforeEach(ParagraphReader) {}
12 AfterEach(ParagraphReader) {}
13
14 Ensure(ParagraphReader, gives_null_when_reading_empty_stream) {
15 assert_that(read_paragraph(&empty_stream, NULL), is_null);
16 }