1
2
3
4
5
6
7
8
9
10
11 package org.mule.module.rss;
12
13 import org.mule.util.IOUtils;
14
15 import java.io.IOException;
16 import java.io.InputStream;
17
18 import static org.junit.Assert.assertNotNull;
19
20
21
22
23 public class SampleFeed
24 {
25 public static final int ENTRIES_IN_RSS_FEED = 25;
26 private static final String FEED_FILE = "sample-feed.rss";
27
28 public static String feedAsString() throws IOException
29 {
30 return IOUtils.getResourceAsString(FEED_FILE, SampleFeed.class);
31 }
32
33 public static InputStream feedAsStream() throws IOException
34 {
35 InputStream stream = IOUtils.getResourceAsStream(FEED_FILE, SampleFeed.class);
36 assertNotNull(stream);
37 return stream;
38 }
39 }