Skip to content

Commit

Permalink
IMPALA-7579: fix test_query_profile_contains_all_events on S3
Browse files Browse the repository at this point in the history
This bug was introduced by IMPALA-6568 which added the
test_query_profile_contains_all_events test. This test creates a file
in the filesystem so that it can be used by 'load data inpath'. The
test was using the hdfs_client object to do file system operations, but
this client only works with hdfs. Switch to using the filesystem_client
object which can work on other filesystems, including s3. Also create
the file that will be moved by 'load data inpath' under the unique
database directory; this means the file can be created without having to
check if it exists already and must be deleted.

Change-Id: I7c6e0899455dd4e12636b959fab4bde79f02fb95
Reviewed-on: http://gerrit.cloudera.org:8080/11461
Reviewed-by: Impala Public Jenkins <[email protected]>
Tested-by: Impala Public Jenkins <[email protected]>
  • Loading branch information
bartash authored and cloudera-hudson committed Sep 19, 2018
1 parent d22da79 commit 7c7329d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tests/query_test/test_observability.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,8 @@ def __verify_profile_event_sequence(self, event_regexes, runtime_profile):
def test_query_profile_contains_all_events(self, unique_database):
"""Test that the expected events show up in a query profile for various queries"""
# make a data file to load data from
path = "tmp/{0}/data_file".format(unique_database)
self.hdfs_client.delete_file_dir(path)
self.hdfs_client.create_file(path, "1")
path = "test-warehouse/{0}.db/data_file".format(unique_database)
self.filesystem_client.create_file(path, "1")
use_query = "use {0}".format(unique_database)
self.execute_query(use_query)
# all the events we will see for every query
Expand Down

0 comments on commit 7c7329d

Please sign in to comment.