This is an automated email from the ASF dual-hosted git repository.

wonook pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nemo.git


The following commit(s) were added to refs/heads/master by this push:
     new ad5386f  [NEMO-2, 106, 117] Remove the /tests directory (#69)
ad5386f is described below

commit ad5386f3f083e36eea2df268cdaacb054329ca5a
Author: WooYeon Lee <[email protected]>
AuthorDate: Thu Jul 19 15:42:34 2018 +0900

    [NEMO-2, 106, 117] Remove the /tests directory (#69)
    
    JIRA: [NEMO-2: Remove the /tests 
directory](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-2)
    JIRA: [NEMO-106: Move /tests/compiler into 
/compiler/tests](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-106)
    JIRA: [NEMO-117: Move /tests/runtime/common/DAGConverterTest into 
compiler/backend/test](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-117)
    
    **Major changes:**
    - This PR removes /tests, which has compiler-tests and runtime-tests, by 
moving those tests to corresponding directories (/compiler, /runtime)
    - Because compiler-tests have complex dependencies that make them cannot go 
into the corresponding sub-modules (cyclic dependency), I've created a new 
module named `nemo-compiler-test` (/compiler/test) for such tests.
    
    **Minor changes to note:**
    - Cleanup poms
    - Update .gitignore to ignore /runtime/dag/*, which was /dag/*
    
    **Tests for the changes:**
    - N/A
    
    **Other comments:**
    - N/A
    
    resolves 
[NEMO-2](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-2)
    resolves 
[NEMO-106](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-106)
    resolves 
[NEMO-117](https://issues.apache.org/jira/projects/NEMO/issues/NEMO-117)
---
 .gitignore                                         |  2 +-
 .../edu/snu/nemo/client/ClientEndpointTest.java    |  2 +-
 compiler/backend/pom.xml                           |  6 +++
 .../compiler/backend/nemo/NemoBackendTest.java     |  3 +-
 .../optimizer/policy/PolicyBuilderTest.java        |  3 +-
 {tests => compiler/test}/pom.xml                   | 35 +++++++++++++++--
 .../edu/snu/nemo}/compiler/CompilerTestUtil.java   | 44 ++++++++++++++++++----
 .../compiler/optimizer/policy/TestPolicy.java      |  3 +-
 .../compiler/backend/nemo}/DAGConverterTest.java   |  4 +-
 .../frontend/beam/BeamFrontendALSTest.java         |  4 +-
 .../frontend/beam/BeamFrontendMLRTest.java         |  4 +-
 .../annotating/DefaultEdgeCoderPassTest.java       |  7 +---
 .../annotating/DefaultParallelismPassTest.java     |  6 +--
 .../annotating/DefaultScheduleGroupPassTest.java   |  8 ++--
 .../composite/DataSkewCompositePassTest.java       |  6 +--
 .../composite/DisaggregationPassTest.java          |  5 +--
 .../composite/PadoCompositePassTest.java           |  5 +--
 .../compiletime/composite/SailfishPassTest.java    |  5 +--
 .../CommonSubexpressionEliminationPassTest.java    |  3 +-
 .../reshaping/LoopExtractionPassTest.java          |  5 +--
 .../compiletime/reshaping/LoopFusionPassTest.java  |  6 +--
 .../LoopInvariantCodeMotionALSInefficientTest.java |  6 +--
 .../reshaping/LoopInvariantCodeMotionPassTest.java |  6 +--
 .../reshaping/LoopUnrollingPassTest.java           |  6 +--
 pom.xml                                            |  4 +-
 .../common/plan/PhysicalPlanGeneratorTest.java     |  0
 .../runtime/common/plan/StagePartitionerTest.java  |  0
 .../nemo/runtime/executor}/MetricFlushTest.java    |  6 +--
 runtime/master/pom.xml                             |  2 +-
 .../nemo/runtime/master/JobStateManagerTest.java   |  2 +-
 .../scheduler/BatchSingleJobSchedulerTest.java     |  3 +-
 .../SchedulingConstraintnRegistryTest.java         |  0
 .../runtime/master/scheduler/TaskRetryTest.java    |  2 +-
 runtime/{plangenerator => test}/pom.xml            |  4 +-
 .../runtime/common/plan}/TestPlanGenerator.java    |  6 +--
 35 files changed, 123 insertions(+), 90 deletions(-)

diff --git a/.gitignore b/.gitignore
index 0ee0ba6..be82d45 100644
--- a/.gitignore
+++ b/.gitignore
@@ -17,7 +17,7 @@ build
 # ----------------------------------------------------------------------
 .sample_output*
 sample_output*
-dag/*
+runtime/dag/*
 *.log
 #
 # ----------------------------------------------------------------------
diff --git a/client/src/test/java/edu/snu/nemo/client/ClientEndpointTest.java 
b/client/src/test/java/edu/snu/nemo/client/ClientEndpointTest.java
index 19f41f5..3f0d1a0 100644
--- a/client/src/test/java/edu/snu/nemo/client/ClientEndpointTest.java
+++ b/client/src/test/java/edu/snu/nemo/client/ClientEndpointTest.java
@@ -20,7 +20,7 @@ import edu.snu.nemo.runtime.common.state.JobState;
 import edu.snu.nemo.runtime.common.state.TaskState;
 import edu.snu.nemo.runtime.master.MetricMessageHandler;
 import edu.snu.nemo.runtime.master.JobStateManager;
-import edu.snu.nemo.runtime.plangenerator.TestPlanGenerator;
+import edu.snu.nemo.runtime.common.plan.TestPlanGenerator;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.powermock.core.classloader.annotations.PrepareForTest;
diff --git a/compiler/backend/pom.xml b/compiler/backend/pom.xml
index 679575d..8b6c5bc 100644
--- a/compiler/backend/pom.xml
+++ b/compiler/backend/pom.xml
@@ -46,5 +46,11 @@ limitations under the License.
             <artifactId>nemo-runtime-common</artifactId>
             <version>${project.version}</version>
         </dependency>
+        <dependency>
+            <groupId>edu.snu.nemo</groupId>
+            <artifactId>nemo-compiler-optimizer</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
     </dependencies>
 </project>
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/backend/nemo/NemoBackendTest.java
 
b/compiler/backend/src/test/java/edu/snu/nemo/compiler/backend/nemo/NemoBackendTest.java
similarity index 97%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/backend/nemo/NemoBackendTest.java
rename to 
compiler/backend/src/test/java/edu/snu/nemo/compiler/backend/nemo/NemoBackendTest.java
index 1ffd866..f93a9b6 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/backend/nemo/NemoBackendTest.java
+++ 
b/compiler/backend/src/test/java/edu/snu/nemo/compiler/backend/nemo/NemoBackendTest.java
@@ -13,14 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.backend.nemo;
+package edu.snu.nemo.compiler.backend.nemo;
 
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import 
edu.snu.nemo.common.ir.edge.executionproperty.DataCommunicationPatternProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.OperatorVertex;
-import edu.snu.nemo.compiler.backend.nemo.NemoBackend;
 import edu.snu.nemo.common.dag.DAGBuilder;
 import edu.snu.nemo.compiler.optimizer.CompiletimeOptimizer;
 import edu.snu.nemo.common.test.EmptyComponents;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/PolicyBuilderTest.java
 
b/compiler/optimizer/src/test/java/edu/snu/nemo/compiler/optimizer/policy/PolicyBuilderTest.java
similarity index 95%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/PolicyBuilderTest.java
rename to 
compiler/optimizer/src/test/java/edu/snu/nemo/compiler/optimizer/policy/PolicyBuilderTest.java
index b6ac067..7f96cfa 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/PolicyBuilderTest.java
+++ 
b/compiler/optimizer/src/test/java/edu/snu/nemo/compiler/optimizer/policy/PolicyBuilderTest.java
@@ -13,12 +13,11 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.policy;
+package edu.snu.nemo.compiler.optimizer.policy;
 
 import edu.snu.nemo.common.exception.CompileTimeOptimizationException;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultScheduleGroupPass;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.composite.PadoCompositePass;
-import edu.snu.nemo.compiler.optimizer.policy.*;
 import org.junit.Test;
 
 import static org.junit.Assert.assertEquals;
diff --git a/tests/pom.xml b/compiler/test/pom.xml
similarity index 61%
rename from tests/pom.xml
rename to compiler/test/pom.xml
index a7ca69b..4c30dbf 100644
--- a/tests/pom.xml
+++ b/compiler/test/pom.xml
@@ -22,11 +22,11 @@ limitations under the License.
         <groupId>edu.snu.nemo</groupId>
         <artifactId>nemo-project</artifactId>
         <version>0.1-SNAPSHOT</version>
-        <relativePath>../</relativePath>
+        <relativePath>../../</relativePath>
     </parent>
 
-    <artifactId>nemo-tests</artifactId>
-    <name>Nemo Unit Tests</name>
+    <artifactId>nemo-compiler-test</artifactId>
+    <name>Nemo Compiler Test</name>
 
     <repositories>
         <repository>
@@ -48,8 +48,35 @@ limitations under the License.
         </dependency>
         <dependency>
             <groupId>edu.snu.nemo</groupId>
+            <artifactId>nemo-compiler-frontend-beam</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>edu.snu.nemo</groupId>
             <artifactId>nemo-examples-beam</artifactId>
             <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <version>${junit.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.mockito</groupId>
+            <artifactId>mockito-core</artifactId>
+            <version>${mockito.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-module-junit4</artifactId>
+            <version>${powermock.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-mockito2</artifactId>
+            <version>${powermock.version}</version>
         </dependency>
     </dependencies>
-</project>
+</project>
\ No newline at end of file
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/CompilerTestUtil.java 
b/compiler/test/src/main/java/edu/snu/nemo/compiler/CompilerTestUtil.java
similarity index 75%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/CompilerTestUtil.java
rename to 
compiler/test/src/main/java/edu/snu/nemo/compiler/CompilerTestUtil.java
index d5f17f4..ec5a770 100644
--- a/tests/src/test/java/edu/snu/nemo/tests/compiler/CompilerTestUtil.java
+++ b/compiler/test/src/main/java/edu/snu/nemo/compiler/CompilerTestUtil.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler;
+package edu.snu.nemo.compiler;
 
 import edu.snu.nemo.common.test.ArgBuilder;
 import edu.snu.nemo.conf.JobConf;
@@ -27,13 +27,43 @@ import org.apache.reef.tang.Tang;
 import org.mockito.ArgumentCaptor;
 import org.powermock.api.mockito.PowerMockito;
 
+import java.io.File;
 import java.lang.reflect.Method;
 
 /**
  * Utility methods for tests.
  */
 public final class CompilerTestUtil {
-  private static final String rootDir = System.getProperty("user.dir");
+  private static final String ROOT_DIR = 
findRoot(System.getProperty("user.dir"));
+
+  // Utility classes should not have a public or default constructor
+  private CompilerTestUtil() {
+
+  }
+
+  /**
+   * Find the root directory of Nemo project, ascending directory hierarchy 
one by one starting from {@code curDir}.
+   * This method distinguishes the root with "LICENSE" file.
+   * @param curDir the current directory
+   * @return the absolute path of the root directory
+   */
+  private static String findRoot(final String curDir) {
+    boolean foundRoot = false;
+    File folder = new File(curDir);
+
+    while (!foundRoot) {
+      folder = folder.getParentFile();
+      final File[] listOfFiles = folder.listFiles();
+      for (final File file : listOfFiles) {
+        if (file.isFile() && file.getName().equals("LICENSE")) {
+          foundRoot = true;
+          break;
+        }
+      }
+    }
+
+    return folder.getAbsolutePath();
+  }
 
   private static DAG<IRVertex, IREdge> compileDAG(final String[] args) throws 
Exception {
     final String userMainClassName;
@@ -60,8 +90,8 @@ public final class CompilerTestUtil {
   }
 
   public static DAG<IRVertex, IREdge> compileWordCountDAG() throws Exception {
-    final String input = rootDir + 
"/../examples/resources/sample_input_wordcount";
-    final String output = rootDir + "/../examples/resources/sample_output";
+    final String input = ROOT_DIR + 
"/examples/resources/sample_input_wordcount";
+    final String output = ROOT_DIR + "/examples/resources/sample_output";
     final String main = "edu.snu.nemo.examples.beam.WordCount";
 
     final ArgBuilder mrArgBuilder = new ArgBuilder()
@@ -72,7 +102,7 @@ public final class CompilerTestUtil {
   }
 
   public static DAG<IRVertex, IREdge> compileALSDAG() throws Exception {
-    final String input = rootDir + "/../examples/resources/sample_input_als";
+    final String input = ROOT_DIR + "/examples/resources/sample_input_als";
     final String numFeatures = "10";
     final String numIteration = "3";
     final String main = "edu.snu.nemo.examples.beam.AlternatingLeastSquare";
@@ -85,7 +115,7 @@ public final class CompilerTestUtil {
   }
 
   public static DAG<IRVertex, IREdge> compileALSInefficientDAG() throws 
Exception {
-    final String input = rootDir + "/../examples/resources/sample_input_als";
+    final String input = ROOT_DIR + "/examples/resources/sample_input_als";
     final String numFeatures = "10";
     final String numIteration = "3";
     final String main = 
"edu.snu.nemo.examples.beam.AlternatingLeastSquareInefficient";
@@ -98,7 +128,7 @@ public final class CompilerTestUtil {
   }
 
   public static DAG<IRVertex, IREdge> compileMLRDAG() throws Exception {
-    final String input = rootDir + "/../examples/resources/sample_input_mlr";
+    final String input = ROOT_DIR + "/examples/resources/sample_input_mlr";
     final String numFeatures = "100";
     final String numClasses = "5";
     final String numIteration = "3";
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/TestPolicy.java
 
b/compiler/test/src/main/java/edu/snu/nemo/compiler/optimizer/policy/TestPolicy.java
similarity index 93%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/TestPolicy.java
rename to 
compiler/test/src/main/java/edu/snu/nemo/compiler/optimizer/policy/TestPolicy.java
index 59dbd4e..aca4791 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/policy/TestPolicy.java
+++ 
b/compiler/test/src/main/java/edu/snu/nemo/compiler/optimizer/policy/TestPolicy.java
@@ -13,11 +13,10 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.policy;
+package edu.snu.nemo.compiler.optimizer.policy;
 
 import edu.snu.nemo.compiler.optimizer.pass.compiletime.CompileTimePass;
 import edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.*;
-import edu.snu.nemo.compiler.optimizer.policy.Policy;
 import edu.snu.nemo.runtime.common.optimizer.pass.runtime.RuntimePass;
 
 import java.util.*;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/runtime/common/plan/DAGConverterTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/backend/nemo/DAGConverterTest.java
similarity index 99%
rename from 
tests/src/test/java/edu/snu/nemo/tests/runtime/common/plan/DAGConverterTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/backend/nemo/DAGConverterTest.java
index 5175045..6702b44 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/runtime/common/plan/DAGConverterTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/backend/nemo/DAGConverterTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.runtime.common.plan;
+package edu.snu.nemo.compiler.backend.nemo;
 
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.dag.DAGBuilder;
@@ -34,7 +34,7 @@ import edu.snu.nemo.conf.JobConf;
 import edu.snu.nemo.runtime.common.plan.PhysicalPlanGenerator;
 import edu.snu.nemo.runtime.common.plan.Stage;
 import edu.snu.nemo.runtime.common.plan.StageEdge;
-import edu.snu.nemo.tests.compiler.optimizer.policy.TestPolicy;
+import edu.snu.nemo.compiler.optimizer.policy.TestPolicy;
 import org.apache.reef.tang.Injector;
 import org.apache.reef.tang.Tang;
 import org.junit.Before;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendALSTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendALSTest.java
similarity index 95%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendALSTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendALSTest.java
index c5bf207..27872c2 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendALSTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendALSTest.java
@@ -13,13 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.frontend.beam;
+package edu.snu.nemo.compiler.frontend.beam;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.powermock.core.classloader.annotations.PrepareForTest;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendMLRTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendMLRTest.java
similarity index 95%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendMLRTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendMLRTest.java
index bc8440f..8553263 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/frontend/beam/BeamFrontendMLRTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/frontend/beam/BeamFrontendMLRTest.java
@@ -13,13 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.frontend.beam;
+package edu.snu.nemo.compiler.frontend.beam;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.powermock.core.classloader.annotations.PrepareForTest;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
similarity index 91%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
index 7f9dc3a..e21ee55 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultEdgeCoderPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.annotating;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.coder.DecoderFactory;
@@ -23,10 +23,7 @@ import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.edge.executionproperty.DecoderProperty;
 import edu.snu.nemo.common.ir.edge.executionproperty.EncoderProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.AnnotatingPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultEdgeDecoderPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultEdgeEncoderPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
similarity index 89%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
index 105eeb8..59c54c2 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultParallelismPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.annotating;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -21,9 +21,7 @@ import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.SourceVertex;
 import edu.snu.nemo.common.ir.vertex.executionproperty.ParallelismProperty;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.AnnotatingPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultParallelismPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
similarity index 97%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
index 7d1f588..585c40b 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/annotating/DefaultScheduleGroupPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.annotating;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.Pair;
@@ -27,11 +27,9 @@ import edu.snu.nemo.common.ir.vertex.OperatorVertex;
 import edu.snu.nemo.common.ir.vertex.executionproperty.ScheduleGroupProperty;
 import edu.snu.nemo.common.ir.vertex.transform.Transform;
 import edu.snu.nemo.common.test.EmptyComponents;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import edu.snu.nemo.compiler.optimizer.CompiletimeOptimizer;
-import edu.snu.nemo.tests.compiler.optimizer.policy.TestPolicy;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.AnnotatingPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultScheduleGroupPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.optimizer.policy.TestPolicy;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.powermock.core.classloader.annotations.PrepareForTest;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
similarity index 94%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
index 8345b05..4034748 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DataSkewCompositePassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.composite;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.composite;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -24,11 +24,9 @@ import 
edu.snu.nemo.common.ir.edge.executionproperty.PartitionerProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.MetricCollectionBarrierVertex;
 import edu.snu.nemo.common.ir.executionproperty.ExecutionProperty;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import 
edu.snu.nemo.common.ir.vertex.executionproperty.SkewnessAwareSchedulingProperty;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.AnnotatingPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.composite.CompositePass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.composite.DataSkewCompositePass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
similarity index 91%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
index d4cc616..98775d3 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/DisaggregationPassTest.java
@@ -13,18 +13,17 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.composite;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.composite;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
-import 
edu.snu.nemo.common.ir.edge.executionproperty.DataCommunicationPatternProperty;
 import 
edu.snu.nemo.common.ir.edge.executionproperty.InterTaskDataStoreProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultParallelismPass;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DisaggregationEdgeDataStorePass;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.DefaultInterTaskDataStorePass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
similarity index 95%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
index f983698..3683088 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/PadoCompositePassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.composite;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.composite;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -22,10 +22,9 @@ import 
edu.snu.nemo.common.ir.edge.executionproperty.DataFlowModelProperty;
 import 
edu.snu.nemo.common.ir.edge.executionproperty.InterTaskDataStoreProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import 
edu.snu.nemo.common.ir.vertex.executionproperty.ExecutorPlacementProperty;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.PadoEdgeDataStorePass;
 import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.annotating.PadoVertexExecutorPlacementPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.composite.PadoCompositePass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
similarity index 94%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
index ab1beb7..e49d31a 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/composite/SailfishPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.composite;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.composite;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.coder.BytesDecoderFactory;
@@ -22,8 +22,7 @@ import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.edge.executionproperty.*;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import edu.snu.nemo.compiler.optimizer.pass.compiletime.composite.SailfishPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
similarity index 96%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
index 827e326..1f8b479 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/CommonSubexpressionEliminationPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -23,7 +23,6 @@ import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.OperatorVertex;
 import edu.snu.nemo.common.dag.DAGBuilder;
 import edu.snu.nemo.common.test.EmptyComponents;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.CommonSubexpressionEliminationPass;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
similarity index 87%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
index 4568f68..acccd73 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopExtractionPassTest.java
@@ -13,14 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopExtractionPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
similarity index 96%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
index d2d6954..2a784cf 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopFusionPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -24,9 +24,7 @@ import 
edu.snu.nemo.common.ir.edge.executionproperty.DecoderProperty;
 import edu.snu.nemo.common.ir.edge.executionproperty.EncoderProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.LoopVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopExtractionPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopOptimizations;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
similarity index 86%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
index a74c0c8..64d5b74 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionALSInefficientTest.java
@@ -13,15 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopExtractionPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopOptimizations;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
similarity index 94%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
index a461873..1159921 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopInvariantCodeMotionPassTest.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.dag.DAG;
@@ -24,9 +24,7 @@ import 
edu.snu.nemo.common.ir.edge.executionproperty.DecoderProperty;
 import edu.snu.nemo.common.ir.edge.executionproperty.EncoderProperty;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
 import edu.snu.nemo.common.ir.vertex.LoopVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopExtractionPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopOptimizations;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
similarity index 89%
rename from 
tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
rename to 
compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
index 684bfc9..5f823f1 100644
--- 
a/tests/src/test/java/edu/snu/nemo/tests/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
+++ 
b/compiler/test/src/test/java/edu/snu/nemo/compiler/optimizer/pass/compiletime/reshaping/LoopUnrollingPassTest.java
@@ -13,16 +13,14 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.tests.compiler.optimizer.pass.compiletime.reshaping;
+package edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping;
 
 import edu.snu.nemo.client.JobLauncher;
 import edu.snu.nemo.common.Pair;
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.ir.edge.IREdge;
 import edu.snu.nemo.common.ir.vertex.IRVertex;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopExtractionPass;
-import 
edu.snu.nemo.compiler.optimizer.pass.compiletime.reshaping.LoopUnrollingPass;
-import edu.snu.nemo.tests.compiler.CompilerTestUtil;
+import edu.snu.nemo.compiler.CompilerTestUtil;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
diff --git a/pom.xml b/pom.xml
index aa8837d..2929ec2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -60,14 +60,14 @@ limitations under the License.
         <module>compiler/frontend/beam</module>
         <module>compiler/frontend/spark</module>
         <module>compiler/optimizer</module>
+        <module>compiler/test</module>
         <module>examples/beam</module>
         <module>examples/spark</module>
         <module>runtime/common</module>
         <module>runtime/executor</module>
         <module>runtime/master</module>
         <module>runtime/driver</module>
-        <module>runtime/plangenerator</module>
-        <module>tests</module>
+        <module>runtime/test</module>
     </modules>
 
     <dependencies>
diff --git 
a/tests/src/test/java/edu/snu/nemo/runtime/common/plan/PhysicalPlanGeneratorTest.java
 
b/runtime/common/src/test/java/edu/snu/nemo/runtime/common/plan/PhysicalPlanGeneratorTest.java
similarity index 100%
rename from 
tests/src/test/java/edu/snu/nemo/runtime/common/plan/PhysicalPlanGeneratorTest.java
rename to 
runtime/common/src/test/java/edu/snu/nemo/runtime/common/plan/PhysicalPlanGeneratorTest.java
diff --git 
a/tests/src/test/java/edu/snu/nemo/runtime/common/plan/StagePartitionerTest.java
 
b/runtime/common/src/test/java/edu/snu/nemo/runtime/common/plan/StagePartitionerTest.java
similarity index 100%
rename from 
tests/src/test/java/edu/snu/nemo/runtime/common/plan/StagePartitionerTest.java
rename to 
runtime/common/src/test/java/edu/snu/nemo/runtime/common/plan/StagePartitionerTest.java
diff --git 
a/tests/src/test/java/edu/snu/nemo/runtime/master/MetricFlushTest.java 
b/runtime/executor/src/test/java/edu/snu/nemo/runtime/executor/MetricFlushTest.java
similarity index 95%
rename from tests/src/test/java/edu/snu/nemo/runtime/master/MetricFlushTest.java
rename to 
runtime/executor/src/test/java/edu/snu/nemo/runtime/executor/MetricFlushTest.java
index ea8237a..7497ecb 100644
--- a/tests/src/test/java/edu/snu/nemo/runtime/master/MetricFlushTest.java
+++ 
b/runtime/executor/src/test/java/edu/snu/nemo/runtime/executor/MetricFlushTest.java
@@ -13,13 +13,13 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.runtime.master;
+package edu.snu.nemo.runtime.executor;
 
 import edu.snu.nemo.runtime.common.comm.ControlMessage;
 import edu.snu.nemo.runtime.common.message.*;
 import edu.snu.nemo.runtime.common.message.local.LocalMessageDispatcher;
 import edu.snu.nemo.runtime.common.message.local.LocalMessageEnvironment;
-import edu.snu.nemo.runtime.executor.MetricManagerWorker;
+import edu.snu.nemo.runtime.master.MetricManagerMaster;
 import edu.snu.nemo.runtime.master.resource.ExecutorRepresenter;
 import edu.snu.nemo.runtime.master.scheduler.ExecutorRegistry;
 import org.apache.reef.tang.Configuration;
@@ -43,7 +43,7 @@ import static org.mockito.Mockito.doAnswer;
 import static org.mockito.Mockito.mock;
 
 /**
- * Ensures metrics collected by {@link 
edu.snu.nemo.runtime.executor.MetricManagerWorker} are properly sent to master
+ * Ensures metrics collected by {@link MetricManagerWorker} are properly sent 
to master
  * before the job finishes.
  */
 @RunWith(PowerMockRunner.class)
diff --git a/runtime/master/pom.xml b/runtime/master/pom.xml
index 8ea4688..dace8c9 100644
--- a/runtime/master/pom.xml
+++ b/runtime/master/pom.xml
@@ -48,7 +48,7 @@ limitations under the License.
         </dependency>
         <dependency>
             <groupId>edu.snu.nemo</groupId>
-            <artifactId>nemo-runtime-plangenerator</artifactId>
+            <artifactId>nemo-runtime-test</artifactId>
             <version>${project.version}</version>
         </dependency>
         <dependency>
diff --git 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/JobStateManagerTest.java
 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/JobStateManagerTest.java
index 803fa40..73176be 100644
--- 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/JobStateManagerTest.java
+++ 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/JobStateManagerTest.java
@@ -25,7 +25,7 @@ import edu.snu.nemo.runtime.common.plan.Stage;
 import edu.snu.nemo.runtime.common.state.JobState;
 import edu.snu.nemo.runtime.common.state.StageState;
 import edu.snu.nemo.runtime.common.state.TaskState;
-import edu.snu.nemo.runtime.plangenerator.TestPlanGenerator;
+import edu.snu.nemo.runtime.common.plan.TestPlanGenerator;
 import org.apache.reef.tang.Injector;
 import org.junit.Before;
 import org.junit.Test;
diff --git 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/BatchSingleJobSchedulerTest.java
 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/BatchSingleJobSchedulerTest.java
index 44fb64c..935f310 100644
--- 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/BatchSingleJobSchedulerTest.java
+++ 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/BatchSingleJobSchedulerTest.java
@@ -23,7 +23,6 @@ import edu.snu.nemo.runtime.common.message.MessageSender;
 import edu.snu.nemo.runtime.common.plan.PhysicalPlan;
 import edu.snu.nemo.runtime.common.plan.Stage;
 import edu.snu.nemo.runtime.common.plan.StageEdge;
-import edu.snu.nemo.runtime.common.state.StageState;
 import edu.snu.nemo.runtime.master.JobStateManager;
 import edu.snu.nemo.runtime.master.MetricMessageHandler;
 import edu.snu.nemo.runtime.master.BlockManagerMaster;
@@ -32,7 +31,7 @@ import edu.snu.nemo.runtime.master.resource.ContainerManager;
 import edu.snu.nemo.runtime.master.resource.ExecutorRepresenter;
 import edu.snu.nemo.runtime.master.resource.ResourceSpecification;
 import edu.snu.nemo.common.dag.DAG;
-import edu.snu.nemo.runtime.plangenerator.TestPlanGenerator;
+import edu.snu.nemo.runtime.common.plan.TestPlanGenerator;
 import org.apache.reef.driver.context.ActiveContext;
 import org.apache.reef.tang.Injector;
 import org.apache.reef.tang.Tang;
diff --git 
a/tests/src/test/java/edu/snu/nemo/runtime/master/scheduler/SchedulingConstraintnRegistryTest.java
 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/SchedulingConstraintnRegistryTest.java
similarity index 100%
rename from 
tests/src/test/java/edu/snu/nemo/runtime/master/scheduler/SchedulingConstraintnRegistryTest.java
rename to 
runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/SchedulingConstraintnRegistryTest.java
diff --git 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/TaskRetryTest.java
 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/TaskRetryTest.java
index fe5ee17..d9b9b30 100644
--- 
a/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/TaskRetryTest.java
+++ 
b/runtime/master/src/test/java/edu/snu/nemo/runtime/master/scheduler/TaskRetryTest.java
@@ -28,7 +28,7 @@ import edu.snu.nemo.runtime.master.MetricMessageHandler;
 import edu.snu.nemo.runtime.master.eventhandler.UpdatePhysicalPlanEventHandler;
 import edu.snu.nemo.runtime.master.resource.ExecutorRepresenter;
 import edu.snu.nemo.runtime.master.resource.ResourceSpecification;
-import edu.snu.nemo.runtime.plangenerator.TestPlanGenerator;
+import edu.snu.nemo.runtime.common.plan.TestPlanGenerator;
 import org.apache.reef.driver.context.ActiveContext;
 import org.apache.reef.tang.Injector;
 import org.apache.reef.tang.Tang;
diff --git a/runtime/plangenerator/pom.xml b/runtime/test/pom.xml
similarity index 94%
rename from runtime/plangenerator/pom.xml
rename to runtime/test/pom.xml
index ffdfe93..96887fe 100644
--- a/runtime/plangenerator/pom.xml
+++ b/runtime/test/pom.xml
@@ -25,8 +25,8 @@ limitations under the License.
         <relativePath>../../</relativePath>
     </parent>
 
-    <artifactId>nemo-runtime-plangenerator</artifactId>
-    <name>Nemo Runtime Test Plans</name>
+    <artifactId>nemo-runtime-test</artifactId>
+    <name>Nemo Runtime Test</name>
 
     <repositories>
         <repository>
diff --git 
a/runtime/plangenerator/src/main/java/edu/snu/nemo/runtime/plangenerator/TestPlanGenerator.java
 
b/runtime/test/src/main/java/edu/snu/nemo/runtime/common/plan/TestPlanGenerator.java
similarity index 96%
rename from 
runtime/plangenerator/src/main/java/edu/snu/nemo/runtime/plangenerator/TestPlanGenerator.java
rename to 
runtime/test/src/main/java/edu/snu/nemo/runtime/common/plan/TestPlanGenerator.java
index 25b26d3..04c2b06 100644
--- 
a/runtime/plangenerator/src/main/java/edu/snu/nemo/runtime/plangenerator/TestPlanGenerator.java
+++ 
b/runtime/test/src/main/java/edu/snu/nemo/runtime/common/plan/TestPlanGenerator.java
@@ -13,7 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package edu.snu.nemo.runtime.plangenerator;
+package edu.snu.nemo.runtime.common.plan;
 
 import edu.snu.nemo.common.dag.DAG;
 import edu.snu.nemo.common.dag.DAGBuilder;
@@ -30,10 +30,6 @@ import 
edu.snu.nemo.compiler.optimizer.policy.BasicPullPolicy;
 import edu.snu.nemo.compiler.optimizer.policy.BasicPushPolicy;
 import edu.snu.nemo.compiler.optimizer.policy.Policy;
 import edu.snu.nemo.conf.JobConf;
-import edu.snu.nemo.runtime.common.plan.PhysicalPlan;
-import edu.snu.nemo.runtime.common.plan.PhysicalPlanGenerator;
-import edu.snu.nemo.runtime.common.plan.Stage;
-import edu.snu.nemo.runtime.common.plan.StageEdge;
 import org.apache.reef.tang.Injector;
 import org.apache.reef.tang.Tang;
 import org.apache.reef.tang.exceptions.InjectionException;

Reply via email to