language: java
sudo: false
install: true
-jdk: oraclejdk7
+jdk: oraclejdk8
script: ./travis.sh
env:
<parent>
<groupId>org.sonarsource.parent</groupId>
<artifactId>parent</artifactId>
- <version>31</version>
+ <version>34</version>
</parent>
<groupId>org.sonarsource.sonarqube</groupId>
<artifactId>sonarqube</artifactId>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.min.version>3.2</maven.min.version>
- <jdk.min.version>1.7</jdk.min.version>
<timestamp>${maven.build.timestamp}</timestamp>
<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ssZ</maven.build.timestamp.format>
<license.title>SonarQube</license.title>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
- <version>2.0.0</version>
+ <version>3.4.1</version>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-guava</artifactId>
- <version>1.3.1</version>
+ <version>3.0.0</version>
</dependency>
<dependency>
<groupId>xpp3</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<executions>
<execution>
- <id>enforce-java7</id>
+ <id>enforce-java8</id>
<goals>
<goal>enforce</goal>
</goals>
<requireJavaVersion>
<message>To release this project JDK ${jdk.min.version} is required.
</message>
- <version>[1.7,)</version>
+ <version>[${jdk.min.version},)</version>
</requireJavaVersion>
</rules>
</configuration>
issue.setLocations("[1-3]");
boolean updated = updater.setLocations(issue, "[1-4]");
assertThat(updated).isTrue();
- assertThat(issue.getLocations()).isEqualTo("[1-4]");
+ assertThat(issue.getLocations().toString()).isEqualTo("[1-4]");
assertThat(issue.currentChange()).isNull();
assertThat(issue.mustSendNotifications()).isFalse();
}
issue.setLocations("[1-3]");
boolean updated = updater.setLocations(issue, "[1-3]");
assertThat(updated).isFalse();
- assertThat(issue.getLocations()).isEqualTo("[1-3]");
+ assertThat(issue.getLocations().toString()).isEqualTo("[1-3]");
assertThat(issue.currentChange()).isNull();
assertThat(issue.mustSendNotifications()).isFalse();
}
issue.setLocations(null);
boolean updated = updater.setLocations(issue, "[1-4]");
assertThat(updated).isTrue();
- assertThat(issue.getLocations()).isEqualTo("[1-4]");
+ assertThat(issue.getLocations().toString()).isEqualTo("[1-4]");
assertThat(issue.currentChange()).isNull();
assertThat(issue.mustSendNotifications()).isFalse();
}
BaseDoc doc = new BaseDoc(fields) {
};
- assertThat(doc.getNullableField("a_string")).isEqualTo("foo");
- assertThat(doc.getNullableField("a_int")).isEqualTo(42);
- assertThat(doc.getNullableField("a_null")).isNull();
+ assertThat((String) doc.getNullableField("a_string")).isEqualTo("foo");
+ assertThat((int) doc.getNullableField("a_int")).isEqualTo(42);
+ assertThat((String) doc.getNullableField("a_null")).isNull();
}
@Test
@Test
public void getFieldAsDate() {
- BaseDoc doc = new BaseDoc(Maps.<String,Object>newHashMap()) {
+ BaseDoc doc = new BaseDoc(Maps.newHashMap()) {
};
long now = System.currentTimeMillis();
doc.setField("javaDate", new Date(now));
@Test
public void getNullableFieldAsDate() {
- BaseDoc doc = new BaseDoc(Maps.<String,Object>newHashMap()) {
+ BaseDoc doc = new BaseDoc(Maps.newHashMap()) {
};
long now = System.currentTimeMillis();
doc.setField("javaDate", new Date(now));