public class SentimentAnalyzerTest {
@Test
public void testSentimentAnalyzer() {
SentimentAnalyzer analyzer = new SentimentAnalyzer();
analyzer.init();
TimelineMusic meta = new TimelineMusic();
SentimentResult result = analyzer.getSentiment(Sets.newHashSet("This sucks", "Too bad it didn't happen", "Not cool, man"), meta);
assertEquals(SentimentResult.NEGATIVE, result);
result = analyzer.getSentiment(Sets.newHashSet("Whatever", "I'm coming tomorrow by bus", "Three cities participated in the campagin"), meta);
assertEquals(SentimentResult.NEUTRAL, result);
result = analyzer.getSentiment(Sets.newHashSet("Brilliant job", "Nice one, mate", "I really appreciate your effort"), meta);
assertEquals(SentimentResult.POSITIVE, result);
}