You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@streams.apache.org by sb...@apache.org on 2016/12/17 19:58:59 UTC
[6/9] incubator-streams-examples git commit: switch
twitter-follow-neo4j to testng
switch twitter-follow-neo4j to testng
Project: http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/commit/c4821b6f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/tree/c4821b6f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/diff/c4821b6f
Branch: refs/heads/master
Commit: c4821b6f3d4c36e92e63cf5b4db115bef7cc2d61
Parents: 846b5cb
Author: Steve Blackmon @steveblackmon <sb...@apache.org>
Authored: Thu Dec 15 13:01:57 2016 -0600
Committer: Steve Blackmon @steveblackmon <sb...@apache.org>
Committed: Thu Dec 15 13:01:57 2016 -0600
----------------------------------------------------------------------
local/twitter-follow-neo4j/pom.xml | 29 +++++++++++++-------
.../example/test/TwitterFollowNeo4jIT.java | 15 ++++------
2 files changed, 24 insertions(+), 20 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/blob/c4821b6f/local/twitter-follow-neo4j/pom.xml
----------------------------------------------------------------------
diff --git a/local/twitter-follow-neo4j/pom.xml b/local/twitter-follow-neo4j/pom.xml
index 30bbb24..0921867 100644
--- a/local/twitter-follow-neo4j/pom.xml
+++ b/local/twitter-follow-neo4j/pom.xml
@@ -39,6 +39,18 @@
<dependencies>
<dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <version>${testng.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.hamcrest</groupId>
+ <artifactId>hamcrest-all</artifactId>
+ <version>1.3</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>com.typesafe</groupId>
<artifactId>config</artifactId>
</dependency>
@@ -223,16 +235,13 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
- <version>2.12.4</version>
- <executions>
- <execution>
- <id>integration-tests</id>
- <goals>
- <goal>integration-test</goal>
- <goal>verify</goal>
- </goals>
- </execution>
- </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.maven.surefire</groupId>
+ <artifactId>surefire-testng</artifactId>
+ <version>${failsafe.plugin.version}</version>
+ </dependency>
+ </dependencies>
</plugin>
</plugins>
</build>
http://git-wip-us.apache.org/repos/asf/incubator-streams-examples/blob/c4821b6f/local/twitter-follow-neo4j/src/test/java/org/apache/streams/example/test/TwitterFollowNeo4jIT.java
----------------------------------------------------------------------
diff --git a/local/twitter-follow-neo4j/src/test/java/org/apache/streams/example/test/TwitterFollowNeo4jIT.java b/local/twitter-follow-neo4j/src/test/java/org/apache/streams/example/test/TwitterFollowNeo4jIT.java
index 0eed291..51593b0 100644
--- a/local/twitter-follow-neo4j/src/test/java/org/apache/streams/example/test/TwitterFollowNeo4jIT.java
+++ b/local/twitter-follow-neo4j/src/test/java/org/apache/streams/example/test/TwitterFollowNeo4jIT.java
@@ -26,18 +26,13 @@ import org.apache.streams.config.StreamsConfiguration;
import org.apache.streams.config.StreamsConfigurator;
import org.apache.streams.example.TwitterFollowNeo4j;
import org.apache.streams.example.TwitterFollowNeo4jConfiguration;
-import org.junit.Before;
-import org.junit.Test;
+
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import org.testng.annotations.BeforeClass;
+import org.testng.annotations.Test;
import java.io.File;
-import java.io.FileInputStream;
-import java.io.InputStream;
-import java.util.Properties;
-
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotEquals;
/**
* Example stream that populates elasticsearch with activities from twitter userstream in real-time
@@ -50,11 +45,11 @@ public class TwitterFollowNeo4jIT {
private int count = 0;
- @Before
+ @BeforeClass
public void prepareTest() throws Exception {
Config reference = ConfigFactory.load();
- File conf_file = new File("target/test-classes/TwitterFollowGraphIT.conf");
+ File conf_file = new File("target/test-classes/TwitterFollowNeo4jIT.conf");
assert(conf_file.exists());
Config testResourceConfig = ConfigFactory.parseFileAnySyntax(conf_file, ConfigParseOptions.defaults().setAllowMissing(false));
Config typesafe = testResourceConfig.withFallback(reference).resolve();