use of org.apache.zeppelin.cassandra.TextBlockHierarchy.SimpleStm in project zeppelin by apache.
the class InterpreterLogicTest method should_generate_simple_statement.
@Test
public void should_generate_simple_statement() {
// Given
String input = "SELECT * FROM users LIMIT 10;";
CassandraQueryOptions options = new CassandraQueryOptions(Option.apply(QUORUM), Option.empty(), Option.empty(), Option.empty(), Option.empty());
// When
final SimpleStatement actual = helper.generateSimpleStatement(new SimpleStm(input), options, intrContext);
// Then
assertThat(actual).isNotNull();
assertThat(actual.getQuery()).isEqualTo("SELECT * FROM users LIMIT 10;");
assertThat(actual.getConsistencyLevel()).isSameAs(QUORUM);
}
Aggregations