diff options
author | Matei Zaharia <matei@databricks.com> | 2013-12-28 23:17:58 -0500 |
---|---|---|
committer | Matei Zaharia <matei@databricks.com> | 2013-12-28 23:17:58 -0500 |
commit | 20631348d198ba52059f278c1b415c3a80a95b81 (patch) | |
tree | 02212ec0ad07a97b19595155129cb52ae610d582 /streaming/src/test/java/org/apache | |
parent | 0900d5c72aaf6670bb9fcce8e0c0cfa976adcdf7 (diff) | |
download | spark-20631348d198ba52059f278c1b415c3a80a95b81.tar.gz spark-20631348d198ba52059f278c1b415c3a80a95b81.tar.bz2 spark-20631348d198ba52059f278c1b415c3a80a95b81.zip |
Fix other failing tests
Diffstat (limited to 'streaming/src/test/java/org/apache')
-rw-r--r-- | streaming/src/test/java/org/apache/spark/streaming/JavaAPISuite.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/streaming/src/test/java/org/apache/spark/streaming/JavaAPISuite.java b/streaming/src/test/java/org/apache/spark/streaming/JavaAPISuite.java index a1db0995e3..d53d433693 100644 --- a/streaming/src/test/java/org/apache/spark/streaming/JavaAPISuite.java +++ b/streaming/src/test/java/org/apache/spark/streaming/JavaAPISuite.java @@ -25,6 +25,7 @@ import com.google.common.io.Files; import kafka.serializer.StringDecoder; import org.apache.hadoop.mapreduce.lib.input.SequenceFileInputFormat; +import org.apache.spark.SparkConf; import org.apache.spark.streaming.api.java.JavaDStreamLike; import org.junit.After; import org.junit.Assert; @@ -62,14 +63,16 @@ public class JavaAPISuite implements Serializable { @Before public void setUp() { - System.setProperty("spark.streaming.clock", "org.apache.spark.streaming.util.ManualClock"); - ssc = new JavaStreamingContext("local[2]", "test", new Duration(1000)); + SparkConf conf = new SparkConf() + .setMaster("local[2]") + .setAppName("test") + .set("spark.streaming.clock", "org.apache.spark.streaming.util.ManualClock"); + ssc = new JavaStreamingContext(conf, new Duration(1000)); ssc.checkpoint("checkpoint"); } @After public void tearDown() { - System.clearProperty("spark.streaming.clock"); ssc.stop(); ssc = null; |