This is an automated email from the ASF dual-hosted git repository.
eolivelli pushed a commit to branch branch-4.10
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git
The following commit(s) were added to refs/heads/branch-4.10 by this push:
new 40ed497 fix: TableStoreImplTest failed because of NPE in
AbstractStateStoreWithJournal initialization (test/mock issue)
40ed497 is described below
commit 40ed497ce48a8306bf7db1c5a417e8cf9daff6d0
Author: Andrey Yegorov <[email protected]>
AuthorDate: Tue Feb 2 01:13:08 2021 -0800
fix: TableStoreImplTest failed because of NPE in
AbstractStateStoreWithJournal initialization (test/mock issue)
Descriptions of the changes in this PR:
fixed mock creation.
### Motivation
tests fail
### Changes
fixed mock creation
Master Issue: #2572
Reviewers: Enrico Olivelli <[email protected]>
This closes #2573 from dlg99/master-fix-tabletest-npe
---
.../bookkeeper/stream/storage/impl/store/MVCCAsyncStoreTestBase.java | 1 +
1 file changed, 1 insertion(+)
diff --git
a/stream/storage/impl/src/test/java/org/apache/bookkeeper/stream/storage/impl/store/MVCCAsyncStoreTestBase.java
b/stream/storage/impl/src/test/java/org/apache/bookkeeper/stream/storage/impl/store/MVCCAsyncStoreTestBase.java
index 318cba0..de3bc81 100644
---
a/stream/storage/impl/src/test/java/org/apache/bookkeeper/stream/storage/impl/store/MVCCAsyncStoreTestBase.java
+++
b/stream/storage/impl/src/test/java/org/apache/bookkeeper/stream/storage/impl/store/MVCCAsyncStoreTestBase.java
@@ -57,6 +57,7 @@ public abstract class MVCCAsyncStoreTestBase {
when(namespace.openLog(anyString())).thenReturn(dlm);
AsyncLogWriter logWriter = mock(AsyncLogWriter.class);
when(dlm.openAsyncLogWriter()).thenReturn(FutureUtils.value(logWriter));
+
when(dlm.openAsyncLogWriter(any())).thenReturn(FutureUtils.value(logWriter));
when(logWriter.getLastTxId()).thenReturn(-1L);
DLSN dlsn = new DLSN(0L, 0L, 0L);
when(logWriter.write(any(LogRecord.class))).thenReturn(FutureUtils.value(dlsn));