From a362a67a4b01882e4752c93e2ca0e01f646e699a Mon Sep 17 00:00:00 2001 From: zhli1142015 Date: Tue, 23 Apr 2024 10:11:41 -0700 Subject: [PATCH] Fix build error in abfs test (#9577) Summary: Fix CI failure in [Linux Build / Linux release with adapters (pull_request)](https://github.com/facebookincubator/velox/actions/runs/8793602118/job/24131750229?pr=9478): ``` /__w/velox/velox/./velox/connectors/hive/storage_adapters/abfs/tests/MockBlobStorageFileClient.h:30:27: error: 'using element_type = class facebook::velox::exec::test::TempFilePath' {aka 'class facebook::velox::exec::test::TempFilePath'} has no member named 'path'; did you mean 'const string facebook::velox::exec::test::TempFilePath::path_'? (accessible via 'const string& facebook::velox::exec::test::TempFilePath::getPath() const') 30 | filePath_ = tempFile->path; | ^~~~ | getPath() ``` ``` /__w/velox/velox/velox/connectors/hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp:69:38: error: 'using element_type = class facebook::velox::exec::test::TempFilePath' {aka 'class facebook::velox::exec::test::TempFilePath'} has no member named 'path'; did you mean 'const string facebook::velox::exec::test::TempFilePath::path_'? (accessible via 'const string& facebook::velox::exec::test::TempFilePath::getPath() const') 69 | azuriteServer->addFile(tempFile->path, filePath); | ^~~~ | getPath() ``` Pull Request resolved: https://github.com/facebookincubator/velox/pull/9577 Reviewed By: bikramSingh91 Differential Revision: D56471534 Pulled By: Yuhta fbshipit-source-id: 99bfe31590d346e4140820a5d1bdbb72e0660410 --- .../hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp | 2 +- .../storage_adapters/abfs/tests/MockBlobStorageFileClient.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/velox/connectors/hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp b/velox/connectors/hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp index da3bd28176a0..66ababa2ea3e 100644 --- a/velox/connectors/hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp +++ b/velox/connectors/hive/storage_adapters/abfs/tests/AbfsFileSystemTest.cpp @@ -66,7 +66,7 @@ class AbfsFileSystemTest : public testing::Test { azuriteServer = std::make_shared(port); azuriteServer->start(); auto tempFile = createFile(); - azuriteServer->addFile(tempFile->path, filePath); + azuriteServer->addFile(tempFile->getPath(), filePath); } void TearDown() override { diff --git a/velox/connectors/hive/storage_adapters/abfs/tests/MockBlobStorageFileClient.h b/velox/connectors/hive/storage_adapters/abfs/tests/MockBlobStorageFileClient.h index 046cb094c1b1..1ef79b31c8b7 100644 --- a/velox/connectors/hive/storage_adapters/abfs/tests/MockBlobStorageFileClient.h +++ b/velox/connectors/hive/storage_adapters/abfs/tests/MockBlobStorageFileClient.h @@ -27,7 +27,7 @@ class MockBlobStorageFileClient : public IBlobStorageFileClient { public: MockBlobStorageFileClient() { auto tempFile = ::exec::test::TempFilePath::create(); - filePath_ = tempFile->path; + filePath_ = tempFile->getPath(); } void create() override;