mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-09-27 14:59:09 +02:00
refactoring
This commit is contained in:
@@ -17,6 +17,9 @@ import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.mockito.Mockito;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import static org.mockito.ArgumentMatchers.any;
|
||||
import static org.mockito.ArgumentMatchers.eq;
|
||||
|
||||
@@ -68,7 +71,8 @@ class WoodcuttingTest extends MMOTestEnvironment {
|
||||
// wire block
|
||||
Mockito.when(blockState.getBlock()).thenReturn(block);
|
||||
|
||||
Mockito.when(blockState.getBlock().getDrops(any())).thenReturn(null);
|
||||
// return empty collection if ItemStack
|
||||
Mockito.when(blockState.getBlock().getDrops(any())).thenReturn(Collections.EMPTY_LIST);
|
||||
Mockito.when(blockState.getType()).thenReturn(Material.OAK_LOG);
|
||||
woodcuttingManager.processBonusDropCheck(blockState);
|
||||
|
||||
|
Reference in New Issue
Block a user