kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jkr...@apache.org
Subject git commit: TRIVIAL: Fix failing producer integration tests.
Date Thu, 27 Feb 2014 22:25:24 GMT
Repository: kafka
Updated Branches:
  refs/heads/trunk eb6da5749 -> a810b8ecb


TRIVIAL: Fix failing producer integration tests.


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

Branch: refs/heads/trunk
Commit: a810b8ecbe66f36f8ef58a440d439a54762b3d9c
Parents: eb6da57
Author: Jay Kreps <jay.kreps@gmail.com>
Authored: Thu Feb 27 14:25:02 2014 -0800
Committer: Jay Kreps <jay.kreps@gmail.com>
Committed: Thu Feb 27 14:25:02 2014 -0800

----------------------------------------------------------------------
 .../kafka/api/ProducerFailureHandlingTest.scala       | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kafka/blob/a810b8ec/core/src/test/scala/integration/kafka/api/ProducerFailureHandlingTest.scala
----------------------------------------------------------------------
diff --git a/core/src/test/scala/integration/kafka/api/ProducerFailureHandlingTest.scala b/core/src/test/scala/integration/kafka/api/ProducerFailureHandlingTest.scala
index b8eb726..4b7c544 100644
--- a/core/src/test/scala/integration/kafka/api/ProducerFailureHandlingTest.scala
+++ b/core/src/test/scala/integration/kafka/api/ProducerFailureHandlingTest.scala
@@ -15,7 +15,7 @@
  * limitations under the License.
  */
 
-package kafka.api.test
+package kafka.api
 
 import org.scalatest.junit.JUnit3Suite
 import org.junit.Test
@@ -218,13 +218,13 @@ class ProducerFailureHandlingTest extends JUnit3Suite with ZooKeeperTestHarness
 
     // create a record with incorrect partition id, send should fail
     val record = new ProducerRecord(topic1, new Integer(1), "key".getBytes, "value".getBytes)
-    intercept[KafkaException] {
+    intercept[IllegalArgumentException] {
       producer1.send(record)
     }
-    intercept[KafkaException] {
+    intercept[IllegalArgumentException] {
       producer2.send(record)
     }
-    intercept[KafkaException] {
+    intercept[IllegalArgumentException] {
       producer3.send(record)
     }
   }
@@ -244,15 +244,15 @@ class ProducerFailureHandlingTest extends JUnit3Suite with ZooKeeperTestHarness
     producer2.send(record).get
     producer3.send(record).get
 
-    intercept[KafkaException] {
+    intercept[IllegalStateException] {
       producer1.close
       producer1.send(record)
     }
-    intercept[KafkaException] {
+    intercept[IllegalStateException] {
       producer2.close
       producer2.send(record)
     }
-    intercept[KafkaException] {
+    intercept[IllegalStateException] {
       producer3.close
       producer3.send(record)
     }


Mime
View raw message