sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject sqoop git commit: SQOOP-2004: Sqoop2: Make annotations run always
Date Thu, 15 Jan 2015 15:42:12 GMT
Repository: sqoop
Updated Branches:
  refs/heads/sqoop2 3f8cd0a7c -> 819b13802


SQOOP-2004: Sqoop2: Make annotations run always

(Abraham Elmahrek via Jarek Jarcec Cecho)


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/819b1380
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/819b1380
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/819b1380

Branch: refs/heads/sqoop2
Commit: 819b13802ae48d54f8c0c6a156de27a1d28251ea
Parents: 3f8cd0a
Author: Jarek Jarcec Cecho <jarcec@apache.org>
Authored: Thu Jan 15 07:41:48 2015 -0800
Committer: Jarek Jarcec Cecho <jarcec@apache.org>
Committed: Thu Jan 15 07:41:48 2015 -0800

----------------------------------------------------------------------
 .../java/org/apache/sqoop/client/TestSqoopClient.java     |  2 +-
 .../validation/validators/TestHostAndPortValidator.java   |  2 +-
 .../sqoop/connector/jdbc/GenericJdbcExecutorTest.java     |  2 +-
 .../org/apache/sqoop/connector/jdbc/TestExtractor.java    |  4 ++--
 .../apache/sqoop/connector/jdbc/TestFromInitializer.java  |  4 ++--
 .../connector/jdbc/TestGenericJdbcConnectorUpgrader.java  |  2 +-
 .../java/org/apache/sqoop/connector/jdbc/TestLoader.java  |  4 ++--
 .../apache/sqoop/connector/jdbc/TestToInitializer.java    |  4 ++--
 .../org/apache/sqoop/connector/hdfs/TestExtractor.java    |  4 ++--
 .../java/org/apache/sqoop/connector/hdfs/TestLoader.java  |  4 ++--
 .../org/apache/sqoop/connector/hdfs/TestPartitioner.java  |  4 ++--
 .../org/apache/sqoop/connector/kafka/TestKafkaLoader.java |  4 ++--
 .../org/apache/sqoop/connector/kite/TestKiteExecutor.java |  4 ++--
 .../apache/sqoop/connector/kite/TestKiteExtractor.java    |  2 +-
 .../sqoop/connector/kite/TestKiteFromInitializer.java     |  2 +-
 .../org/apache/sqoop/connector/kite/TestKiteLoader.java   |  2 +-
 .../apache/sqoop/connector/kite/TestKiteToDestroyer.java  |  2 +-
 .../sqoop/connector/kite/TestKiteToInitializer.java       |  2 +-
 .../connector/idf/TestAVROIntermediateDataFormat.java     |  2 +-
 .../connector/idf/TestCSVIntermediateDataFormat.java      |  2 +-
 .../connector/idf/TestJSONIntermediateDataFormat.java     |  2 +-
 .../sqoop/connector/matcher/TestLocationMatcher.java      |  2 +-
 .../apache/sqoop/connector/matcher/TestNameMatcher.java   |  2 +-
 .../org/apache/sqoop/core/TestSqoopConfiguration.java     |  2 +-
 .../org/apache/sqoop/driver/TestDriverConfigUpgrader.java |  2 +-
 .../test/java/org/apache/sqoop/driver/TestJobManager.java |  2 +-
 .../test/java/org/apache/sqoop/driver/TestJobRequest.java |  2 +-
 .../org/apache/sqoop/repository/TestJdbcRepository.java   |  2 +-
 .../java/org/apache/sqoop/job/io/TestSqoopWritable.java   |  2 +-
 .../org/apache/sqoop/job/mr/TestMRConfigurationUtils.java |  2 +-
 .../sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java   |  2 +-
 .../org/apache/sqoop/repository/derby/DerbyTestCase.java  |  4 ++--
 .../sqoop/repository/derby/TestConnectorHandling.java     |  2 +-
 .../apache/sqoop/repository/derby/TestDriverHandling.java |  2 +-
 .../org/apache/sqoop/repository/derby/TestInputTypes.java |  2 +-
 .../apache/sqoop/repository/derby/TestJobHandling.java    |  2 +-
 .../apache/sqoop/repository/derby/TestLinkHandling.java   |  2 +-
 .../sqoop/repository/derby/TestRepositoryUpgrade.java     |  2 +-
 .../sqoop/repository/derby/TestSubmissionHandling.java    |  2 +-
 .../sqoop/repository/postgresql/PostgresqlTestCase.java   | 10 +++++-----
 .../apache/sqoop/test/testcases/ConnectorTestCase.java    |  6 +++---
 .../sqoop/test/testcases/KafkaConnectorTestCase.java      |  4 ++--
 .../org/apache/sqoop/test/testcases/TomcatTestCase.java   | 10 +++++-----
 .../connector/jdbc/generic/PartitionerTest.java           |  1 +
 44 files changed, 65 insertions(+), 64 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/client/src/test/java/org/apache/sqoop/client/TestSqoopClient.java
----------------------------------------------------------------------
diff --git a/client/src/test/java/org/apache/sqoop/client/TestSqoopClient.java b/client/src/test/java/org/apache/sqoop/client/TestSqoopClient.java
index 91e34c1..0c6fa62 100644
--- a/client/src/test/java/org/apache/sqoop/client/TestSqoopClient.java
+++ b/client/src/test/java/org/apache/sqoop/client/TestSqoopClient.java
@@ -53,7 +53,7 @@ public class TestSqoopClient {
   SqoopResourceRequests resourceRequests;
   SqoopClient client;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     resourceRequests = mock(SqoopResourceRequests.class);
     client = new SqoopClient("my-cool-server");

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/common/src/test/java/org/apache/sqoop/validation/validators/TestHostAndPortValidator.java
----------------------------------------------------------------------
diff --git a/common/src/test/java/org/apache/sqoop/validation/validators/TestHostAndPortValidator.java
b/common/src/test/java/org/apache/sqoop/validation/validators/TestHostAndPortValidator.java
index 401d60c..1c726ac 100644
--- a/common/src/test/java/org/apache/sqoop/validation/validators/TestHostAndPortValidator.java
+++ b/common/src/test/java/org/apache/sqoop/validation/validators/TestHostAndPortValidator.java
@@ -27,7 +27,7 @@ public class TestHostAndPortValidator {
 
   AbstractValidator<String> validator = new HostAndPortValidator();
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     validator.reset();
     assertEquals(0, validator.getMessages().size());

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/GenericJdbcExecutorTest.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/GenericJdbcExecutorTest.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/GenericJdbcExecutorTest.java
index 1734a16..c3b8171 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/GenericJdbcExecutorTest.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/GenericJdbcExecutorTest.java
@@ -37,7 +37,7 @@ public class GenericJdbcExecutorTest {
       GenericJdbcTestConstants.URL, null, null);
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     if(executor.existTable(emptyTable)) {
       executor.executeUpdate("DROP TABLE " + emptyTable);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestExtractor.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestExtractor.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestExtractor.java
index 3014ed8..83599d3 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestExtractor.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestExtractor.java
@@ -54,7 +54,7 @@ public class TestExtractor {
     tableName = getClass().getSimpleName().toUpperCase();
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     executor = new GenericJdbcExecutor(GenericJdbcTestConstants.DRIVER,
         GenericJdbcTestConstants.URL, null, null);
@@ -73,7 +73,7 @@ public class TestExtractor {
     }
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() {
     executor.close();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
index 5bdcd99..29a528b 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
@@ -59,7 +59,7 @@ public class TestFromInitializer {
     tableColumns = "ICOL,VCOL";
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     executor = new GenericJdbcExecutor(GenericJdbcTestConstants.DRIVER,
         GenericJdbcTestConstants.URL, null, null);
@@ -108,7 +108,7 @@ public class TestFromInitializer {
     ;
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() {
     executor.close();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestGenericJdbcConnectorUpgrader.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestGenericJdbcConnectorUpgrader.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestGenericJdbcConnectorUpgrader.java
index febb90f..1b1fa7f 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestGenericJdbcConnectorUpgrader.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestGenericJdbcConnectorUpgrader.java
@@ -42,7 +42,7 @@ public class TestGenericJdbcConnectorUpgrader {
 
   private GenericJdbcConnectorUpgrader upgrader;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     upgrader = new GenericJdbcConnectorUpgrader();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestLoader.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestLoader.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestLoader.java
index d299f1d..ba66510 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestLoader.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestLoader.java
@@ -56,7 +56,7 @@ public class TestLoader {
     this.tableName = getClass().getSimpleName().toUpperCase();
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     executor = new GenericJdbcExecutor(GenericJdbcTestConstants.DRIVER,
         GenericJdbcTestConstants.URL, null, null);
@@ -70,7 +70,7 @@ public class TestLoader {
     }
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() {
     executor.close();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestToInitializer.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestToInitializer.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestToInitializer.java
index 01dfab3..a61de7d 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestToInitializer.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestToInitializer.java
@@ -57,7 +57,7 @@ public class TestToInitializer {
     tableColumns = "ICOL,VCOL";
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     executor = new GenericJdbcExecutor(GenericJdbcTestConstants.DRIVER,
         GenericJdbcTestConstants.URL, null, null);
@@ -74,7 +74,7 @@ public class TestToInitializer {
     }
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() {
     executor.close();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestExtractor.java
----------------------------------------------------------------------
diff --git a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestExtractor.java
b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestExtractor.java
index d761b6d..9a5ec5e 100644
--- a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestExtractor.java
+++ b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestExtractor.java
@@ -75,7 +75,7 @@ public class TestExtractor extends TestHdfsBase {
     return parameters.toArray(new Object[0][]);
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     FileUtils.mkdirs(inputDirectory);
     switch (this.outputFileType) {
@@ -89,7 +89,7 @@ public class TestExtractor extends TestHdfsBase {
     }
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() throws IOException {
     FileUtils.delete(inputDirectory);
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
----------------------------------------------------------------------
diff --git a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
index 506dc82..b5ec6da 100644
--- a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
+++ b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestLoader.java
@@ -85,10 +85,10 @@ public class TestLoader extends TestHdfsBase {
     return parameters.toArray(new Object[0][]);
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {}
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() throws IOException {
     FileUtils.delete(outputDirectory);
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestPartitioner.java
----------------------------------------------------------------------
diff --git a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestPartitioner.java
b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestPartitioner.java
index 952932c..4c5b0a0 100644
--- a/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestPartitioner.java
+++ b/connector/connector-hdfs/src/test/java/org/apache/sqoop/connector/hdfs/TestPartitioner.java
@@ -60,7 +60,7 @@ public class TestPartitioner extends TestHdfsBase {
     this.compressionClass = compressionClass;
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     partitioner = new HdfsPartitioner();
     FileUtils.mkdirs(inputDirectory);
@@ -76,7 +76,7 @@ public class TestPartitioner extends TestHdfsBase {
     }
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() throws IOException {
     FileUtils.delete(inputDirectory);
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kafka/src/test/java/org/apache/sqoop/connector/kafka/TestKafkaLoader.java
----------------------------------------------------------------------
diff --git a/connector/connector-kafka/src/test/java/org/apache/sqoop/connector/kafka/TestKafkaLoader.java
b/connector/connector-kafka/src/test/java/org/apache/sqoop/connector/kafka/TestKafkaLoader.java
index f060c35..46c1057 100644
--- a/connector/connector-kafka/src/test/java/org/apache/sqoop/connector/kafka/TestKafkaLoader.java
+++ b/connector/connector-kafka/src/test/java/org/apache/sqoop/connector/kafka/TestKafkaLoader.java
@@ -40,7 +40,7 @@ public class TestKafkaLoader {
   private static KafkaLoader loader;
   private static String TOPIC = "mytopic";
 
-  @BeforeClass
+  @BeforeClass(alwaysRun = true)
   public static void setup() throws IOException {
     testUtil.prepare();
     List<String> topics = new ArrayList<String>(1);
@@ -49,7 +49,7 @@ public class TestKafkaLoader {
     loader = new KafkaLoader();
   }
 
-  @AfterClass
+  @AfterClass(alwaysRun = true)
   public static void tearDown() throws IOException {
     testUtil.tearDown();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExecutor.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExecutor.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExecutor.java
index 3e7d1f1..eed6ee0 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExecutor.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExecutor.java
@@ -60,7 +60,7 @@ public class TestKiteExecutor {
     return new org.powermock.modules.testng.PowerMockObjectFactory();
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
     when(datasetMock.newWriter()).thenReturn(writerMock);
@@ -73,7 +73,7 @@ public class TestKiteExecutor {
     executor = new KiteDatasetExecutor(datasetMock);
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() {
     executor.closeWriter();
     executor.closeReader();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExtractor.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExtractor.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExtractor.java
index d2c2249..08d2cb3 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExtractor.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteExtractor.java
@@ -56,7 +56,7 @@ public class TestKiteExtractor {
     }
   };
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteFromInitializer.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteFromInitializer.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteFromInitializer.java
index 027056f..a60b2fc 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteFromInitializer.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteFromInitializer.java
@@ -37,7 +37,7 @@ public class TestKiteFromInitializer extends PowerMockTestCase {
 
   private KiteFromInitializer initializer;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
     mockStatic(Datasets.class);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteLoader.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteLoader.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteLoader.java
index 8f3a5f8..b18c91e 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteLoader.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteLoader.java
@@ -40,7 +40,7 @@ public class TestKiteLoader {
   @org.mockito.Mock
   private KiteDatasetExecutor executorMock;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToDestroyer.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToDestroyer.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToDestroyer.java
index 8c61e75..3fcc339 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToDestroyer.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToDestroyer.java
@@ -52,7 +52,7 @@ public class TestKiteToDestroyer extends PowerMockTestCase {
   @org.mockito.Mock
   private KiteDatasetExecutor executorMock;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
     mockStatic(KiteDatasetExecutor.class);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToInitializer.java
----------------------------------------------------------------------
diff --git a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToInitializer.java
b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToInitializer.java
index 93efa93..5230ffe 100644
--- a/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToInitializer.java
+++ b/connector/connector-kite/src/test/java/org/apache/sqoop/connector/kite/TestKiteToInitializer.java
@@ -41,7 +41,7 @@ public class TestKiteToInitializer extends PowerMockTestCase {
 
   private KiteToInitializer initializer;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     initMocks(this);
     mockStatic(Datasets.class);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestAVROIntermediateDataFormat.java
----------------------------------------------------------------------
diff --git a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestAVROIntermediateDataFormat.java
b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestAVROIntermediateDataFormat.java
index 5c7b444..dd7a3e1 100644
--- a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestAVROIntermediateDataFormat.java
+++ b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestAVROIntermediateDataFormat.java
@@ -67,7 +67,7 @@ public class TestAVROIntermediateDataFormat {
   private final static org.joda.time.LocalTime time = new org.joda.time.LocalTime(12, 59,
59);
   private final static org.joda.time.LocalDate date = new org.joda.time.LocalDate(2014, 10,
01);
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     createAvroIDF();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestCSVIntermediateDataFormat.java
----------------------------------------------------------------------
diff --git a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestCSVIntermediateDataFormat.java
b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestCSVIntermediateDataFormat.java
index d2b0ae0..2556711 100644
--- a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestCSVIntermediateDataFormat.java
+++ b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestCSVIntermediateDataFormat.java
@@ -53,7 +53,7 @@ public class TestCSVIntermediateDataFormat {
 
   private CSVIntermediateDataFormat dataFormat;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
   }
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestJSONIntermediateDataFormat.java
----------------------------------------------------------------------
diff --git a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestJSONIntermediateDataFormat.java
b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestJSONIntermediateDataFormat.java
index 8a87c65..12c66c2 100644
--- a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestJSONIntermediateDataFormat.java
+++ b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/idf/TestJSONIntermediateDataFormat.java
@@ -52,7 +52,7 @@ public class TestJSONIntermediateDataFormat {
   private final static String dateTime = "'2014-10-01 12:00:00.000'";
   private final static String time = "'12:59:59'";
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     createJSONIDF();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
----------------------------------------------------------------------
diff --git a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
index 624fa7b..f23694d 100644
--- a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
+++ b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestLocationMatcher.java
@@ -29,7 +29,7 @@ public class TestLocationMatcher {
 
   private LocationMatcher matcher;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     matcher = null;
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
----------------------------------------------------------------------
diff --git a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
index 76ff0da..742a35c 100644
--- a/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
+++ b/connector/connector-sdk/src/test/java/org/apache/sqoop/connector/matcher/TestNameMatcher.java
@@ -29,7 +29,7 @@ public class TestNameMatcher {
 
   private NameMatcher matcher;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     matcher = null;
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/core/src/test/java/org/apache/sqoop/core/TestSqoopConfiguration.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/sqoop/core/TestSqoopConfiguration.java b/core/src/test/java/org/apache/sqoop/core/TestSqoopConfiguration.java
index e15691e..956e6ab 100644
--- a/core/src/test/java/org/apache/sqoop/core/TestSqoopConfiguration.java
+++ b/core/src/test/java/org/apache/sqoop/core/TestSqoopConfiguration.java
@@ -26,7 +26,7 @@ import org.testng.annotations.Test;
 
 public class TestSqoopConfiguration {
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     // Unset any configuration dir if it is set by another test
     System.getProperties().remove(ConfigurationConstants.SYSPROP_CONFIG_DIR);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/core/src/test/java/org/apache/sqoop/driver/TestDriverConfigUpgrader.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/sqoop/driver/TestDriverConfigUpgrader.java b/core/src/test/java/org/apache/sqoop/driver/TestDriverConfigUpgrader.java
index ec548d5..d4522ae 100644
--- a/core/src/test/java/org/apache/sqoop/driver/TestDriverConfigUpgrader.java
+++ b/core/src/test/java/org/apache/sqoop/driver/TestDriverConfigUpgrader.java
@@ -39,7 +39,7 @@ public class TestDriverConfigUpgrader {
 
   DriverUpgrader upgrader;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void initializeUpgrader() {
     upgrader = new DriverUpgrader();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/core/src/test/java/org/apache/sqoop/driver/TestJobManager.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/sqoop/driver/TestJobManager.java b/core/src/test/java/org/apache/sqoop/driver/TestJobManager.java
index 926815d..baca35f 100644
--- a/core/src/test/java/org/apache/sqoop/driver/TestJobManager.java
+++ b/core/src/test/java/org/apache/sqoop/driver/TestJobManager.java
@@ -48,7 +48,7 @@ public class TestJobManager {
   private RepositoryManager repositoryManagerMock;
   private Repository jdbcRepoMock;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     jobManager = new JobManager();
     connectorMgrMock = mock(ConnectorManager.class);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/core/src/test/java/org/apache/sqoop/driver/TestJobRequest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/sqoop/driver/TestJobRequest.java b/core/src/test/java/org/apache/sqoop/driver/TestJobRequest.java
index 26560fe..4381b97 100644
--- a/core/src/test/java/org/apache/sqoop/driver/TestJobRequest.java
+++ b/core/src/test/java/org/apache/sqoop/driver/TestJobRequest.java
@@ -33,7 +33,7 @@ public class TestJobRequest {
 
   private JobRequest jobRequest;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void initializeSubmissionRequest() {
     jobRequest = new JobRequest();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/core/src/test/java/org/apache/sqoop/repository/TestJdbcRepository.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/sqoop/repository/TestJdbcRepository.java b/core/src/test/java/org/apache/sqoop/repository/TestJdbcRepository.java
index f804a45..9b153fc 100644
--- a/core/src/test/java/org/apache/sqoop/repository/TestJdbcRepository.java
+++ b/core/src/test/java/org/apache/sqoop/repository/TestJdbcRepository.java
@@ -76,7 +76,7 @@ public class TestJdbcRepository {
   private ConnectorConfigurableUpgrader connectorUpgraderMock;
   private DriverUpgrader driverUpgraderMock;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     repoTransactionMock = mock(JdbcRepositoryTransaction.class);
     connectorMgrMock = mock(ConnectorManager.class);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/execution/mapreduce/src/test/java/org/apache/sqoop/job/io/TestSqoopWritable.java
----------------------------------------------------------------------
diff --git a/execution/mapreduce/src/test/java/org/apache/sqoop/job/io/TestSqoopWritable.java
b/execution/mapreduce/src/test/java/org/apache/sqoop/job/io/TestSqoopWritable.java
index 452e085..85bf73d 100644
--- a/execution/mapreduce/src/test/java/org/apache/sqoop/job/io/TestSqoopWritable.java
+++ b/execution/mapreduce/src/test/java/org/apache/sqoop/job/io/TestSqoopWritable.java
@@ -44,7 +44,7 @@ public class TestSqoopWritable {
   private SqoopWritable writable;
   private IntermediateDataFormat<?> idfMock;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     idfMock = mock(IntermediateDataFormat.class);
     writable = new SqoopWritable(idfMock);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestMRConfigurationUtils.java
----------------------------------------------------------------------
diff --git a/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestMRConfigurationUtils.java
b/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestMRConfigurationUtils.java
index a3e6dee..b83de3b 100644
--- a/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestMRConfigurationUtils.java
+++ b/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestMRConfigurationUtils.java
@@ -44,7 +44,7 @@ public class TestMRConfigurationUtils {
   Job job;
   JobConf jobConfSpy;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     setUpHadoopJob();
     setUpHadoopJobConf();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java
----------------------------------------------------------------------
diff --git a/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java
b/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java
index 41ea24a..71c98db 100644
--- a/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java
+++ b/execution/mapreduce/src/test/java/org/apache/sqoop/job/mr/TestSqoopOutputFormatLoadExecutor.java
@@ -155,7 +155,7 @@ public class TestSqoopOutputFormatLoadExecutor {
     return new Schema("test").addColumn(new Text("t"));
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() {
     conf = new Configuration();
     conf.setIfUnset(MRJobConstants.TO_INTERMEDIATE_DATA_FORMAT,

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/DerbyTestCase.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/DerbyTestCase.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/DerbyTestCase.java
index 1b6bdc0..be8c23e 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/DerbyTestCase.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/DerbyTestCase.java
@@ -60,14 +60,14 @@ abstract public class DerbyTestCase {
 
   private Connection connection;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     // Create link to the database
     Class.forName(DERBY_DRIVER).newInstance();
     connection = DriverManager.getConnection(getStartJdbcUrl());
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() throws Exception {
     // Close active link
     if (connection != null) {

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestConnectorHandling.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestConnectorHandling.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestConnectorHandling.java
index 248873b..ca24398 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestConnectorHandling.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestConnectorHandling.java
@@ -34,7 +34,7 @@ public class TestConnectorHandling extends DerbyTestCase {
 
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
     handler = new DerbyRepositoryHandler();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestDriverHandling.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestDriverHandling.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestDriverHandling.java
index 91d8b92..e12bf46 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestDriverHandling.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestDriverHandling.java
@@ -34,7 +34,7 @@ public class TestDriverHandling extends DerbyTestCase {
   private static final Object CURRENT_DRIVER_VERSION = "1";
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
     handler = new DerbyRepositoryHandler();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestInputTypes.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestInputTypes.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestInputTypes.java
index 2cbe255..fb07152 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestInputTypes.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestInputTypes.java
@@ -48,7 +48,7 @@ public class TestInputTypes extends DerbyTestCase {
 
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestJobHandling.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestJobHandling.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestJobHandling.java
index 3cc6928..458450b 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestJobHandling.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestJobHandling.java
@@ -48,7 +48,7 @@ public class TestJobHandling extends DerbyTestCase {
   DerbyRepositoryHandler handler;
   Connection derbyConnection;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
     derbyConnection = getDerbyDatabaseConnection();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestLinkHandling.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestLinkHandling.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestLinkHandling.java
index 1c96deb..5602c7c 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestLinkHandling.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestLinkHandling.java
@@ -42,7 +42,7 @@ public class TestLinkHandling extends DerbyTestCase {
 
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestRepositoryUpgrade.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestRepositoryUpgrade.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestRepositoryUpgrade.java
index b53aeff..9255882 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestRepositoryUpgrade.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestRepositoryUpgrade.java
@@ -30,7 +30,7 @@ public class TestRepositoryUpgrade extends DerbyTestCase {
 
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
     handler = new TestDerbyRepositoryHandler();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestSubmissionHandling.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestSubmissionHandling.java
b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestSubmissionHandling.java
index 523ddc7..bb96e3c 100644
--- a/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestSubmissionHandling.java
+++ b/repository/repository-derby/src/test/java/org/apache/sqoop/repository/derby/TestSubmissionHandling.java
@@ -38,7 +38,7 @@ public class TestSubmissionHandling extends DerbyTestCase {
 
   DerbyRepositoryHandler handler;
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     super.setUp();
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/repository/repository-postgresql/src/test/java/org/apache/sqoop/repository/postgresql/PostgresqlTestCase.java
----------------------------------------------------------------------
diff --git a/repository/repository-postgresql/src/test/java/org/apache/sqoop/repository/postgresql/PostgresqlTestCase.java
b/repository/repository-postgresql/src/test/java/org/apache/sqoop/repository/postgresql/PostgresqlTestCase.java
index ea199d4..ae546f3 100644
--- a/repository/repository-postgresql/src/test/java/org/apache/sqoop/repository/postgresql/PostgresqlTestCase.java
+++ b/repository/repository-postgresql/src/test/java/org/apache/sqoop/repository/postgresql/PostgresqlTestCase.java
@@ -21,8 +21,8 @@ import org.apache.sqoop.common.test.db.DatabaseProvider;
 import org.apache.sqoop.common.test.db.PostgreSQLProvider;
 import org.testng.SkipException;
 import org.testng.annotations.AfterMethod;
+import org.testng.annotations.BeforeClass;
 import org.testng.annotations.BeforeMethod;
-import org.testng.annotations.Test;
 
 /**
  * Abstract class with convenience methods for testing postgresql repository.
@@ -33,13 +33,13 @@ abstract public class PostgresqlTestCase {
   public static PostgresqlTestUtils utils;
   public PostgresqlRepositoryHandler handler;
 
-  @Test
-  public static void setUpClass() {
+  @BeforeClass(alwaysRun = true)
+  public void setUpClass() {
     provider = new PostgreSQLProvider();
     utils = new PostgresqlTestUtils(provider);
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void setUp() throws Exception {
     try {
       provider.start();
@@ -51,7 +51,7 @@ abstract public class PostgresqlTestCase {
     handler.createOrUpgradeRepository(provider.getConnection());
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void tearDown() throws Exception {
     provider.dropSchema("sqoop");
     provider.stop();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/test/src/main/java/org/apache/sqoop/test/testcases/ConnectorTestCase.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/sqoop/test/testcases/ConnectorTestCase.java b/test/src/main/java/org/apache/sqoop/test/testcases/ConnectorTestCase.java
index e98d091..1124cd3 100644
--- a/test/src/main/java/org/apache/sqoop/test/testcases/ConnectorTestCase.java
+++ b/test/src/main/java/org/apache/sqoop/test/testcases/ConnectorTestCase.java
@@ -75,7 +75,7 @@ abstract public class ConnectorTestCase extends TomcatTestCase {
     }
   };
 
-  @BeforeClass
+  @BeforeClass(alwaysRun = true)
   public static void startHadoop() throws Exception {
     // Start Hadoop Clusters
     hadoopCluster = HadoopRunnerFactory.getHadoopCluster(System.getProperties(), HadoopMiniClusterRunner.class);
@@ -88,14 +88,14 @@ abstract public class ConnectorTestCase extends TomcatTestCase {
     LOG.debug("HDFS Client: " + hdfsClient);
   }
 
-  @BeforeClass
+  @BeforeClass(alwaysRun = true)
   public static void startProvider() throws Exception {
     provider = DatabaseProviderFactory.getProvider(System.getProperties());
     LOG.info("Starting database provider: " + provider.getClass().getName());
     provider.start();
   }
 
-  @AfterClass
+  @AfterClass(alwaysRun = true)
   public static void stopProvider() {
     LOG.info("Stopping database provider: " + provider.getClass().getName());
     provider.stop();

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/test/src/main/java/org/apache/sqoop/test/testcases/KafkaConnectorTestCase.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/sqoop/test/testcases/KafkaConnectorTestCase.java
b/test/src/main/java/org/apache/sqoop/test/testcases/KafkaConnectorTestCase.java
index cc6724e..a65d862 100644
--- a/test/src/main/java/org/apache/sqoop/test/testcases/KafkaConnectorTestCase.java
+++ b/test/src/main/java/org/apache/sqoop/test/testcases/KafkaConnectorTestCase.java
@@ -38,13 +38,13 @@ public class KafkaConnectorTestCase extends ConnectorTestCase {
   private static TestUtil testUtil = TestUtil.getInstance();
   private static final String TOPIC = "mytopic";
 
-  @BeforeClass
+  @BeforeClass(alwaysRun = true)
   public static void startKafka() throws IOException {
     // starts Kafka server and its dependent zookeeper
     testUtil.prepare();
   }
 
-  @AfterClass
+  @AfterClass(alwaysRun = true)
   public static void stopKafka() throws IOException {
     testUtil.tearDown();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/test/src/main/java/org/apache/sqoop/test/testcases/TomcatTestCase.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/sqoop/test/testcases/TomcatTestCase.java b/test/src/main/java/org/apache/sqoop/test/testcases/TomcatTestCase.java
index ce74894..db88294 100644
--- a/test/src/main/java/org/apache/sqoop/test/testcases/TomcatTestCase.java
+++ b/test/src/main/java/org/apache/sqoop/test/testcases/TomcatTestCase.java
@@ -88,7 +88,7 @@ abstract public class TomcatTestCase {
    */
   private SqoopClient client;
 
-  @BeforeClass
+  @BeforeClass(alwaysRun = true)
   public static void startHadoop() throws Exception {
     // Start Hadoop Clusters
     hadoopCluster = HadoopRunnerFactory.getHadoopCluster(System.getProperties(), HadoopLocalRunner.class);
@@ -101,12 +101,12 @@ abstract public class TomcatTestCase {
     LOG.debug("HDFS Client: " + hdfsClient);
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void findMethodName(Method method) {
     name = method.getName();
   }
 
-  @BeforeMethod
+  @BeforeMethod(alwaysRun = true)
   public void startServer() throws Exception {
     // Get and set temporary path in hadoop cluster.
     tmpPath = HdfsUtils.joinPathFragments(TMP_PATH_BASE, getClass().getName(), name);
@@ -122,12 +122,12 @@ abstract public class TomcatTestCase {
     client = new SqoopClient(getServerUrl());
   }
 
-  @AfterMethod
+  @AfterMethod(alwaysRun = true)
   public void stopServer() throws Exception {
     cluster.stop();
   }
 
-  @AfterClass
+  @AfterClass(alwaysRun = true)
   public static void stopHadoop() throws Exception {
     hadoopCluster.stop();
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/819b1380/test/src/test/java/org/apache/sqoop/integration/connector/jdbc/generic/PartitionerTest.java
----------------------------------------------------------------------
diff --git a/test/src/test/java/org/apache/sqoop/integration/connector/jdbc/generic/PartitionerTest.java
b/test/src/test/java/org/apache/sqoop/integration/connector/jdbc/generic/PartitionerTest.java
index 352fb26..f69f08c 100644
--- a/test/src/test/java/org/apache/sqoop/integration/connector/jdbc/generic/PartitionerTest.java
+++ b/test/src/test/java/org/apache/sqoop/integration/connector/jdbc/generic/PartitionerTest.java
@@ -34,6 +34,7 @@ import org.testng.annotations.Test;
 /**
  *
  */
+@Test(groups = "slow")
 public class PartitionerTest extends ConnectorTestCase implements ITest {
 
   /**


Mime
View raw message