Elffuss BraidHub

kikocis/java-driver public

Updateing annotations to work with surefie, changes from review feedback
Changeset1e9ad4f86e72e845dc00e9d665ba788be4be30f949e5c2f44822f4aea0c7b51a
AuthorGregBestland <Greg.Bestland@datastax.com> · 2017-02-27 09:53 -06:00
CommitterGregBestland <Greg.Bestland@datastax.com> · 2017-02-27 09:53 -06:00
Parents1c2a711506e8

Browse the files at this changeset

1 file changed

modified driver-core/src/test/java/com/datastax/driver/core/ConsistencyTest.java +14 −7
@@ -22,6 +22,7 @@
2222 import org.scassandra.http.client.Query;
2323 import org.slf4j.Logger;
2424 import org.slf4j.LoggerFactory;
25+import org.testng.annotations.AfterClass;
2526 import org.testng.annotations.AfterMethod;
2627 import org.testng.annotations.BeforeClass;
2728 import org.testng.annotations.Test;
@@ -37,14 +38,19 @@
3738 private static final Logger logger = LoggerFactory.getLogger(ConsistencyTest.class);
3839 private ScassandraCluster sCluster;
3940
40- @BeforeClass
41+ @BeforeClass(groups = "short")
4142 public void setUp() {
4243 sCluster = ScassandraCluster.builder().withNodes(1).build();
4344 sCluster.init();
4445
4546 }
4647
47- @AfterMethod
48+ @AfterClass(groups = "short")
49+ public void tearDownClass() {
50+ sCluster.stop();
51+ }
52+
53+ @AfterMethod(groups = "short")
4854 public void tearDown() {
4955 clearActivityLog();
5056 }
@@ -63,12 +69,13 @@
6369 .withPort(sCluster.getBinaryPort()).withNettyOptions(nonQuietClusterCloseOptions);
6470 }
6571
72+ /**
73+ * This method checks the expected/sent serial consistency level against that which is received.
74+ * ConsistencyLevel.SERIAL is the default serial consistency level, so even when sent it will return
75+ * as null.
76+ */
6677 public void checkSerialCLMatch(ConsistencyLevel expected, String received) {
67- /**
68- * This method checks the expected/sent serial consistency level against that which is received.
69- * ConsistencyLevel.SERIAL is the default serial consistency level, so even when sent it will return
70- * as null.
71- */
78+
7279 if (expected.equals(ConsistencyLevel.SERIAL)) {
7380 assertNull(received);
7481