Files
impala/testdata/workloads/functional-query/queries/QueryTest/hbase-rowkeys.test
Lenni Kuff ef48f65e76 Add test framework for running Impala query tests via Python
This is the first set of changes required to start getting our functional test
infrastructure moved from JUnit to Python. After investigating a number of
option, I decided to go with a python test executor named py.test
(http://pytest.org/). It is very flexible, open source (MIT licensed), and will
enable us to do some cool things like parallel test execution.

As part of this change, we now use our "test vectors" for query test execution.
This will be very nice because it means if load the "core" dataset you know you
will be able to run the "core" query tests (specified by --exploration_strategy
when running the tests).

You will see that now each combination of table format + query exec options is
treated like an individual test case. this will make it much easier to debug
exactly where something failed.

These new tests can be run using the script at tests/run-tests.sh
2014-01-08 10:46:50 -08:00

117 lines
1.6 KiB
Plaintext

====
---- QUERY
# predicate on row key col is applied to scan if row key is mapped as string col
select count(*)
from hbasestringids
where id = '5'
---- TYPES
bigint
---- RESULTS
1
====
---- QUERY
# predicate on row key col is not applied to scan if row key is mapped as non-string col
# but the result is still correct
select count(*)
from hbasealltypesagg
where id = 5
---- TYPES
bigint
---- RESULTS
1
====
---- QUERY
# ids are stored in ascii and ordered lexicographically
# exclusive upper bound
select count(*)
from hbasestringids
where id < '5'
---- TYPES
bigint
---- RESULTS
4445
====
---- QUERY
# inclusive upper bound
select count(*)
from hbasestringids
where id <= '5'
---- TYPES
bigint
---- RESULTS
4446
====
---- QUERY
# inclusive lower bound
select count(*)
from hbasestringids
where id >= '6'
---- TYPES
bigint
---- RESULTS
4444
====
---- QUERY
# exclusive lower bound
select count(*)
from hbasestringids
where id > '6'
---- TYPES
bigint
---- RESULTS
4443
====
---- QUERY
# combinations
select count(*)
from hbasestringids
where id > '5'
and id < '6'
---- TYPES
bigint
---- RESULTS
1110
====
---- QUERY
select count(*)
from hbasestringids
where id >= '5'
and id < '6'
---- TYPES
bigint
---- RESULTS
1111
====
---- QUERY
select count(*)
from hbasestringids
where id > '5'
and id <= '6'
---- TYPES
bigint
---- RESULTS
1111
====
---- QUERY
select count(*)
from hbasestringids
where id >= '5'
and id <= '6'
---- TYPES
bigint
---- RESULTS
1112
====
---- QUERY
# predicates on non-key cols are evaluated in the executor
# and non-string comparisons work
select count(*)
from hbasestringids
where id < '5'
and smallint_col < 5
---- TYPES
bigint
---- RESULTS
180
====