Skip to content

Commit

Permalink
fix ut
Browse files Browse the repository at this point in the history
  • Loading branch information
xianjingfeng committed Nov 3, 2022
1 parent de961fe commit 3e237ea
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

import org.apache.uniffle.common.util.RssUtils;
import org.apache.uniffle.storage.request.CreateShuffleWriteHandlerRequest;
import org.apache.uniffle.storage.util.StorageType;

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertFalse;
Expand Down Expand Up @@ -168,8 +169,11 @@ public void writeHandlerTest() {
LocalStorage item = LocalStorage.newBuilder().basePath(testBaseDir.getAbsolutePath()).build();
String appId = "writeHandlerTest";
assertFalse(item.containsWriteHandler(appId, 0, 1));
CreateShuffleWriteHandlerRequest createWriterHandlerRequest =
item.getCreateWriterHandlerRequest(appId, 0, 1);
item.containsWriteHandler(appId, 0, 1);
String[] storageBasePaths = {testBaseDir.getAbsolutePath()};
CreateShuffleWriteHandlerRequest request = new CreateShuffleWriteHandlerRequest(
StorageType.LOCALFILE.name(), appId, 0, 1, 1, storageBasePaths,
"ss1", null, 1, null);
item.getOrCreateWriteHandler(request);
assertTrue(item.containsWriteHandler(appId, 0, 1));
}
}

0 comments on commit 3e237ea

Please sign in to comment.