@Test
public void testList() throws Exception {

    streamOperationsService.createStream(StreamsHelper.STREAM_NAME, StreamsHelper.COLUMNS);
    String queryId= streamOperationsService.addQuery(StreamsHelper.STREAM_NAME, StreamsHelper.QUERY);
    streamOperationsService.enableAction(StreamsHelper.STREAM_NAME, StreamAction.LISTEN);
    List<StratioStreamingMessage> list= streamOperationsService.list();
    for (StratioStreamingMessage message: list) {
        if (message.getStreamName().equals(StreamsHelper.STREAM_NAME)) {
            assertEquals("Expected value not found", 1, message.getQueries().size());
            assertEquals("Expected value not found", 6, message.getColumns().size());
        } else {
            assertEquals("Expected value not found", 0, message.getActiveActions().size());
            assertEquals("Expected value not found", 3, message.getColumns().size());
        }
    }
}