kikocis/java-driver public
Changesets · Branches · Tags · Compare
| Changeset | e7dd5f8326716a3af1e56037b7ed60463ba05ef3aa48195a6519f6a1d9d6a220 |
|---|---|
| Author | Alexandre Dutra <alexandre.dutra@datastax.com> · 2016-01-15 10:28 +01:00 |
| Committer | Alexandre Dutra <alexandre.dutra@datastax.com> · 2016-01-16 18:52 +01:00 |
| Parents | 7447708e9957 |
1 file changed
modified driver-core/src/test/java/com/datastax/driver/core/PreparedStatementTest.java +5 −1
| @@ -18,10 +18,12 @@ | ||
| 18 | 18 | import com.datastax.driver.core.exceptions.InvalidQueryException; |
| 19 | 19 | import com.datastax.driver.core.exceptions.UnsupportedFeatureException; |
| 20 | 20 | import com.datastax.driver.core.utils.CassandraVersion; |
| 21 | +import com.google.common.util.concurrent.Uninterruptibles; | |
| 21 | 22 | import org.testng.annotations.Test; |
| 22 | 23 | |
| 23 | 24 | import java.net.InetAddress; |
| 24 | 25 | import java.util.*; |
| 26 | +import java.util.concurrent.TimeUnit; | |
| 25 | 27 | |
| 26 | 28 | import static com.datastax.driver.core.TestUtils.*; |
| 27 | 29 | import static org.assertj.core.api.Assertions.assertThat; |
| @@ -609,7 +611,7 @@ | ||
| 609 | 611 | * @jira_ticket JAVA-777 |
| 610 | 612 | * @since 2.2.0 |
| 611 | 613 | */ |
| 612 | - @Test(groups = "short") | |
| 614 | + @Test(groups = "long") | |
| 613 | 615 | public void should_create_tombstone_when_null_value_on_bound_statement() { |
| 614 | 616 | PreparedStatement prepared = session.prepare("INSERT INTO " + SIMPLE_TABLE + " (k, i) VALUES (?, ?)"); |
| 615 | 617 | BoundStatement st1 = prepared.bind(); |
| @@ -620,6 +622,8 @@ | ||
| 620 | 622 | st2.enableTracing(); |
| 621 | 623 | ResultSet rows = session.execute(st2); |
| 622 | 624 | assertThat(rows.one().isNull(0)).isTrue(); |
| 625 | + // sleep 1 minute to make sure the trace will be complete | |
| 626 | + Uninterruptibles.sleepUninterruptibly(1, TimeUnit.MINUTES); | |
| 623 | 627 | QueryTrace queryTrace = rows.getExecutionInfo().getQueryTrace(); |
| 624 | 628 | assertEventsContain(queryTrace, "1 tombstone"); |
| 625 | 629 | } |