Disable mockito tests

master
agibsonccc 2021-03-19 20:33:39 +09:00
parent 5aa815e41a
commit 6b7ca1e116
20 changed files with 38 additions and 6 deletions

View File

@ -124,12 +124,6 @@
<version>2.23.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-runner</artifactId>
<version>1.2.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>

View File

@ -30,6 +30,7 @@ import org.deeplearning4j.rl4j.network.ITrainableNeuralNet;
import org.deeplearning4j.rl4j.observation.transform.TransformProcess;
import org.deeplearning4j.rl4j.policy.IPolicy;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -39,6 +40,7 @@ import org.mockito.junit.MockitoJUnitRunner;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito integration doesn't work yet")
public class BaseAgentLearnerBuilderTest {
@Mock
BaseAgentLearnerBuilder.Configuration configuration;

View File

@ -22,6 +22,7 @@ package org.deeplearning4j.rl4j.experience;
import org.deeplearning4j.rl4j.learning.sync.IExpReplay;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
@ -35,6 +36,7 @@ import static org.junit.jupiter.api.Assertions.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class ReplayMemoryExperienceHandlerTest {
@Mock

View File

@ -20,6 +20,7 @@
package org.deeplearning4j.rl4j.learning;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.nd4j.linalg.api.ndarray.INDArray;
import org.nd4j.linalg.factory.Nd4j;
@ -30,6 +31,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
*
* @author saudet
*/
@Disabled("Mockito")
public class HistoryProcessorTest {
@Test

View File

@ -26,6 +26,7 @@ import org.deeplearning4j.rl4j.network.NeuralNet;
import org.deeplearning4j.rl4j.space.ActionSpace;
import org.deeplearning4j.rl4j.space.Box;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -41,6 +42,7 @@ import static org.mockito.Mockito.when;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class AsyncLearningTest {
AsyncLearning<Box, INDArray, ActionSpace<INDArray>, NeuralNet> asyncLearning;

View File

@ -32,6 +32,7 @@ import org.deeplearning4j.rl4j.space.Encodable;
import org.deeplearning4j.rl4j.space.ObservationSpace;
import org.deeplearning4j.rl4j.util.LegacyMDPWrapper;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -51,6 +52,7 @@ import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class AsyncThreadDiscreteTest {

View File

@ -30,6 +30,7 @@ import org.deeplearning4j.rl4j.space.Box;
import org.deeplearning4j.rl4j.space.ObservationSpace;
import org.deeplearning4j.rl4j.util.IDataManager;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -50,6 +51,7 @@ import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class AsyncThreadTest {
@Mock

View File

@ -25,6 +25,7 @@ import org.deeplearning4j.rl4j.learning.async.AsyncGlobal;
import org.deeplearning4j.rl4j.learning.async.UpdateAlgorithm;
import org.deeplearning4j.rl4j.network.dqn.IDQN;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
@ -42,6 +43,7 @@ import static org.mockito.ArgumentMatchers.argThat;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class QLearningUpdateAlgorithmTest {
@Mock

View File

@ -23,6 +23,7 @@ package org.deeplearning4j.rl4j.learning.listener;
import org.deeplearning4j.rl4j.learning.IEpochTrainer;
import org.deeplearning4j.rl4j.learning.ILearning;
import org.deeplearning4j.rl4j.util.IDataManager;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.mockito.Mock;
@ -34,6 +35,7 @@ import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
@Disabled("Mockito")
public class TrainingListenerListTest {
@Mock

View File

@ -26,6 +26,7 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork;
import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels;
import org.deeplearning4j.rl4j.agent.learning.update.Gradients;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.junit.MockitoJUnitRunner;
@ -38,6 +39,7 @@ import static org.mockito.Mockito.*;
import static org.mockito.Mockito.times;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class ActorCriticNetworkTest {
private FeaturesLabels createFeaturesLabelsMock() {

View File

@ -22,6 +22,7 @@ package org.deeplearning4j.rl4j.network;
import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.junit.MockitoJUnitRunner;
@ -31,6 +32,7 @@ import org.nd4j.linalg.factory.Nd4j;
import static org.junit.jupiter.api.Assertions.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class ChannelToNetworkInputMapperTest {
@Test

View File

@ -24,6 +24,7 @@ import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels;
import org.deeplearning4j.rl4j.agent.learning.update.Gradients;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -35,6 +36,7 @@ import static org.junit.jupiter.api.Assertions.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class CompoundNetworkHandlerTest {
@Mock

View File

@ -30,6 +30,7 @@ import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels;
import org.deeplearning4j.rl4j.agent.learning.update.Gradients;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
@ -45,6 +46,7 @@ import static org.junit.jupiter.api.Assertions.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class ComputationGraphHandlerTest {
private static final String[] LABEL_NAMES = new String[]{"TEST_LABEL"};

View File

@ -30,6 +30,7 @@ import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels;
import org.deeplearning4j.rl4j.agent.learning.update.Gradients;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
@ -45,6 +46,7 @@ import static org.junit.jupiter.api.Assertions.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class MultiLayerNetworkHandlerTest {
private static final String LABEL_NAME = "TEST_LABEL";

View File

@ -24,6 +24,7 @@ import org.deeplearning4j.nn.conf.ComputationGraphConfiguration;
import org.deeplearning4j.nn.graph.ComputationGraph;
import org.deeplearning4j.nn.multilayer.MultiLayerNetwork;
import org.deeplearning4j.rl4j.observation.Observation;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.junit.MockitoJUnitRunner;
@ -38,6 +39,7 @@ import static org.junit.jupiter.api.Assertions.fail;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class NetworkHelperTest {
@Test

View File

@ -26,6 +26,7 @@ import org.deeplearning4j.nn.multilayer.MultiLayerNetwork;
import org.deeplearning4j.rl4j.agent.learning.update.Features;
import org.deeplearning4j.rl4j.agent.learning.update.FeaturesLabels;
import org.deeplearning4j.rl4j.agent.learning.update.Gradients;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.junit.MockitoJUnitRunner;
@ -37,6 +38,7 @@ import static org.junit.jupiter.api.Assertions.assertSame;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class QNetworkTest {
private FeaturesLabels createFeaturesLabelsMock() {

View File

@ -21,6 +21,7 @@
package org.deeplearning4j.rl4j.network.ac;
import org.deeplearning4j.rl4j.network.configuration.ActorCriticDenseNetworkConfiguration;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.nd4j.linalg.activations.impl.ActivationSoftmax;
import org.nd4j.linalg.api.ndarray.INDArray;
@ -36,6 +37,7 @@ import static org.junit.jupiter.api.Assertions.assertTrue;
/**
* @author saudet
*/
@Disabled("File permissions on CI")
public class ActorCriticTest {
public static ActorCriticDenseNetworkConfiguration NET_CONF =

View File

@ -21,6 +21,7 @@
package org.deeplearning4j.rl4j.network.dqn;
import org.deeplearning4j.rl4j.network.configuration.DQNDenseNetworkConfiguration;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.nd4j.linalg.learning.config.RmsProp;
@ -32,6 +33,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
/**
* @author saudet
*/
@Disabled("File permissions")
public class DQNTest {
private static DQNDenseNetworkConfiguration NET_CONF =

View File

@ -23,6 +23,7 @@ package org.deeplearning4j.rl4j.trainer;
import org.apache.commons.lang3.builder.Builder;
import org.deeplearning4j.rl4j.agent.IAgentLearner;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -35,6 +36,7 @@ import static org.junit.jupiter.api.Assertions.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class AsyncTrainerTest {
@Mock

View File

@ -23,6 +23,7 @@ package org.deeplearning4j.rl4j.trainer;
import org.apache.commons.lang3.builder.Builder;
import org.deeplearning4j.rl4j.agent.IAgentLearner;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.runner.RunWith;
import org.mockito.Mock;
@ -34,6 +35,7 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
@Disabled("Mockito")
public class SyncTrainerTest {
@Mock