Merge remote-tracking branch 'remotes/origin/sprint-1' into ignite-106-2
Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/d23eb01e Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/d23eb01e Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/d23eb01e Branch: refs/heads/ignite-160 Commit: d23eb01e8457c303747a6668db7a3862d6d40788 Parents: a21eae4 20d0d3f Author: ivasilinets <ivasilin...@gridgain.com> Authored: Wed Feb 4 12:20:06 2015 +0300 Committer: ivasilinets <ivasilin...@gridgain.com> Committed: Wed Feb 4 12:20:06 2015 +0300 ---------------------------------------------------------------------- .../fs/GridGgfsCommonAbstractTest.java | 4 +- .../ipc/shmem/GgfsSharedMemoryTestServer.java | 2 +- .../IpcSharedMemoryCrashDetectionSelfTest.java | 2 +- .../IpcSharedMemoryBenchmarkReader.java | 2 +- .../ignite/p2p/GridP2PUndeploySelfTest.java | 2 +- .../GridAbstractCommunicationSelfTest.java | 6 +- ...mmunicationSpiConcurrentConnectSelfTest.java | 6 +- .../tcp/GridTcpCommunicationSpiLanTest.java | 6 +- ...cpCommunicationSpiMultithreadedSelfTest.java | 6 +- ...dTcpCommunicationSpiRecoveryAckSelfTest.java | 6 +- ...GridTcpCommunicationSpiRecoverySelfTest.java | 6 +- .../GridAbstractDiscoverySelfTest.java | 12 +- .../testframework/junits/GridAbstractTest.java | 10 +- .../testframework/junits/GridTestIgnite.java | 230 ----------------- .../testframework/junits/GridTestResources.java | 255 ------------------- .../ignite/testframework/junits/IgniteMock.java | 230 +++++++++++++++++ .../junits/IgniteTestResources.java | 255 +++++++++++++++++++ .../junits/spi/GridSpiAbstractTest.java | 6 +- 18 files changed, 523 insertions(+), 523 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d23eb01e/modules/core/src/test/java/org/apache/ignite/testframework/junits/IgniteMock.java ---------------------------------------------------------------------- diff --cc modules/core/src/test/java/org/apache/ignite/testframework/junits/IgniteMock.java index 0000000,3e9c74d..83c96ae mode 000000,100644..100644 --- a/modules/core/src/test/java/org/apache/ignite/testframework/junits/IgniteMock.java +++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/IgniteMock.java @@@ -1,0 -1,230 +1,230 @@@ + /* @java.file.header */ + + /* _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + + package org.apache.ignite.testframework.junits; + + import org.apache.ignite.*; + import org.apache.ignite.cache.*; + import org.apache.ignite.cache.affinity.*; + import org.apache.ignite.cluster.*; + import org.apache.ignite.configuration.*; + import org.apache.ignite.hadoop.*; + import org.apache.ignite.internal.product.*; + import org.apache.ignite.marshaller.*; + import org.apache.ignite.plugin.*; + import org.apache.ignite.plugin.security.*; + import org.jetbrains.annotations.*; + + import javax.management.*; + import java.util.*; + import java.util.concurrent.*; + + /** + * Ignite mock. + */ + public class IgniteMock implements Ignite { + /** Ignite name */ + private final String name; + + /** Local host. */ + private final String locHost; + + /** */ + private final UUID nodeId; + + /** */ + private IgniteMarshaller marshaller; + + /** */ + private final MBeanServer jmx; + + /** */ + private final String home; + + /** + * Mock values + * + * @param name Name. + * @param locHost Local host. + * @param nodeId Node ID. + * @param marshaller Marshaller. + * @param jmx Jmx Bean Server. + * @param home Ignite home. + */ + public IgniteMock( + String name, String locHost, UUID nodeId, IgniteMarshaller marshaller, MBeanServer jmx, String home) { + this.locHost = locHost; + this.nodeId = nodeId; + this.marshaller = marshaller; + this.jmx = jmx; + this.home = home; + this.name = name; + } + + /** {@inheritDoc} */ + @Override public String name() { + return name; + } + + /** {@inheritDoc} */ + @Override public IgniteLogger log() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteConfiguration configuration() { + IgniteConfiguration cfg = new IgniteConfiguration(); + + cfg.setMarshaller(marshaller); + cfg.setNodeId(nodeId); + cfg.setMBeanServer(jmx); + cfg.setGridGainHome(home); + cfg.setLocalHost(locHost); + + return cfg; + } + + /** {@inheritDoc} */ + @Override public IgniteCluster cluster() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteCompute compute() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteCompute compute(ClusterGroup prj) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteMessaging message() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteMessaging message(ClusterGroup prj) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteEvents events() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteEvents events(ClusterGroup prj) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteManaged managed() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteManaged managed(ClusterGroup prj) { + return null; + } + + /** {@inheritDoc} */ + @Override public ExecutorService executorService() { + return null; + } + + /** {@inheritDoc} */ + @Override public ExecutorService executorService(ClusterGroup prj) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteProduct product() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteScheduler scheduler() { + return null; + } + + /** {@inheritDoc} */ + @Override public GridSecurity security() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgnitePortables portables() { + return null; + } + + /** {@inheritDoc} */ + @Override public <K, V> GridCache<K, V> cache(@Nullable String name) { + return null; + } + + /** {@inheritDoc} */ + @Override public Collection<GridCache<?, ?>> caches() { + return null; + } + + /** {@inheritDoc} */ + @Override public <K, V> IgniteCache<K, V> jcache(@Nullable String name) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteTransactions transactions() { + return null; + } + + /** {@inheritDoc} */ + @Override public <K, V> IgniteDataLoader<K, V> dataLoader(@Nullable String cacheName) { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteFs fileSystem(String name) { + return null; + } + + /** {@inheritDoc} */ + @Override public Collection<IgniteFs> fileSystems() { + return null; + } + + /** {@inheritDoc} */ + @Override public GridHadoop hadoop() { + return null; + } + + /** {@inheritDoc} */ + @Override public IgniteStreamer streamer(@Nullable String name) { + return null; + } + + /** {@inheritDoc} */ + @Override public Collection<IgniteStreamer> streamers() { + return null; + } + + /** {@inheritDoc} */ + @Override public <T extends IgnitePlugin> T plugin(String name) throws PluginNotFoundException { + return null; + } + + /** {@inheritDoc} */ - @Override public void close() throws IgniteCheckedException {} ++ @Override public void close() {} + + /** {@inheritDoc} */ + @Override public <K> CacheAffinity<K> affinity(String cacheName) { + return null; + } + }