Change-Id: I4639f791febc29d7f89ee5905e043b5dcb1071dc
This commit is contained in:
Wei-Chiu Chuang 2023-04-19 13:36:28 -07:00
parent bf7c689fd7
commit 00bc6a1f6b
No known key found for this signature in database
GPG Key ID: B362E1C021854B9D
1 changed files with 4 additions and 1 deletions

View File

@ -26,6 +26,8 @@ import static org.junit.Assert.assertTrue;
import java.io.File;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
import java.util.List;
import java.util.Random;
import org.apache.hadoop.conf.Configuration;
@ -415,8 +417,9 @@ public class TestFSUtils {
* Note: currently the default policy is set to defer to HDFS and this case is to verify the
* logic, will need to remove the check if the default policy is changed
*/
private void verifyNoHDFSApiInvocationForDefaultPolicy() {
private void verifyNoHDFSApiInvocationForDefaultPolicy() throws URISyntaxException, IOException {
FileSystem testFs = new AlwaysFailSetStoragePolicyFileSystem();
testFs.initialize(new URI("hdfs://localhost/"), conf);
// There should be no exception thrown when setting to default storage policy, which indicates
// the HDFS API hasn't been called
try {