Skip to content

Commit 6bf1267

Browse files
committed
test(db): add real-resource close test to restore coverage
1 parent 70add8b commit 6bf1267

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

framework/src/test/java/org/tron/core/db/CheckPointV2StoreTest.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ public static void destroy() {
4141
Args.clearParam();
4242
}
4343

44+
@Test
45+
public void testCloseWithRealResources() {
46+
CheckPointV2Store store = new CheckPointV2Store("test-close-real");
47+
// Exercises the real writeOptions.close() and dbSource.closeDB() code paths
48+
store.close();
49+
}
50+
4451
@Test
4552
public void testCloseReleasesAllResources() throws Exception {
4653
CheckPointV2Store store = new CheckPointV2Store("test-close");

0 commit comments

Comments
 (0)