Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade many dependencies #1242

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -107,17 +107,17 @@
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.3</version>
<version>2.11.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-compress</artifactId>
<version>1.19</version>
<version>1.21</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.9</version>
<version>3.12.0</version>
</dependency>
<dependency>
<groupId>org.arquillian.cube</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public String getDisplayChar() {
final List<TimeUnit> timeUnits = Arrays.asList(TimeUnit.values());
Collections.reverse(timeUnits);

TIME_UNIT_ORDER = (TimeUnit[]) timeUnits.toArray();
TIME_UNIT_ORDER = timeUnits.toArray(new TimeUnit[0]);
}

static {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
import org.arquillian.cube.docker.impl.client.config.Network;
import org.arquillian.cube.docker.impl.client.config.PortBinding;
import org.arquillian.cube.docker.impl.docker.compose.DockerComposeEnvironmentVarResolver;
import org.yaml.snakeyaml.DumperOptions;
import org.yaml.snakeyaml.LoaderOptions;
import org.yaml.snakeyaml.Yaml;
import org.yaml.snakeyaml.constructor.Constructor;
import org.yaml.snakeyaml.introspector.Property;
Expand Down Expand Up @@ -54,7 +56,8 @@ public static String[] reverse(String[] cubeIds) {
}

public static String dump(DockerCompositions containers) {
Yaml yaml = new Yaml(new CubeRepresenter());
DumperOptions dumperOptions = new DumperOptions();
Yaml yaml = new Yaml(new CubeRepresenter(dumperOptions), dumperOptions);
return yaml.dump(containers);
}

Expand All @@ -70,7 +73,8 @@ public static DockerCompositions load(InputStream inputStream) {

final String content = DockerComposeEnvironmentVarResolver.replaceParameters(inputStream);

Yaml yaml = new Yaml(new CubeConstructor());
LoaderOptions loadingOptions = new LoaderOptions();
Yaml yaml = new Yaml(new CubeConstructor(loadingOptions));
Map<String, Object> rawLoad = (Map<String, Object>) yaml.load(content);

DockerCompositions containers = new DockerCompositions();
Expand Down Expand Up @@ -115,7 +119,8 @@ private static DockerCompositions applyExtendsRules(DockerCompositions dockerCom
}

private static class CubeRepresenter extends Representer {
public CubeRepresenter() {
public CubeRepresenter(DumperOptions options) {
super(options);
this.representers.put(PortBinding.class, new ToStringRepresent());
this.representers.put(ExposedPort.class, new ToStringRepresent());
this.representers.put(Image.class, new ToStringRepresent());
Expand All @@ -141,7 +146,8 @@ public Node representData(Object data) {
}

public static class CubeConstructor extends Constructor {
public CubeConstructor() {
public CubeConstructor(LoaderOptions loadingConfig) {
super(loadingConfig);
this.yamlClassConstructors.put(NodeId.scalar, new CubeMapping());
}

Expand Down
7 changes: 0 additions & 7 deletions docker/drone/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
import org.jboss.arquillian.drone.spi.Instantiator;
import org.jboss.arquillian.drone.webdriver.configuration.WebDriverConfiguration;
import org.openqa.selenium.WebDriverException;
import org.openqa.selenium.remote.Browser;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.openqa.selenium.remote.RemoteWebDriver;

Expand Down Expand Up @@ -53,12 +54,12 @@ private DesiredCapabilities getDesiredCapabilities() {
final SeleniumContainers seleniumContainers = seleniumContainersInstance.get();
switch (seleniumContainers.getBrowser()) {
case "firefox":
return DesiredCapabilities.firefox();
return new DesiredCapabilities(Browser.FIREFOX.browserName(), null, null);
case "chrome":
return DesiredCapabilities.chrome();
return new DesiredCapabilities(Browser.CHROME.browserName(), null, null);
// Never should happen since it is protected inside selenium containers class
default:
return DesiredCapabilities.firefox();
return new DesiredCapabilities(Browser.FIREFOX.browserName(), null, null);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,9 @@ public void shouldCreateContainerForFirefox() {

final SeleniumContainers firefox = SeleniumContainers.create("firefox", cubeDroneConfiguration);
assertThat(firefox.getBrowser(), is("firefox"));
assertThat(firefox.getSeleniumContainer().getImage().toString(), is("selenium/standalone-firefox-debug:2.53.0"));
assertThat(firefox.getSeleniumContainer().getImage().toString(), is("selenium/standalone-firefox-debug:4.1.1"));
assertThat(firefox.getSeleniumContainer().getPortBindings(), hasItem(PortBinding.valueOf("14444->4444")));
assertThat(firefox.getSeleniumContainer().getAwait().getResponseCode(), is(403));
assertThat(firefox.getSeleniumContainer().getAwait().getResponseCode(), is(200));
}

@Test
Expand All @@ -116,9 +116,9 @@ public void shouldCreateContainerForChrome() {

final SeleniumContainers firefox = SeleniumContainers.create("chrome", cubeDroneConfiguration);
assertThat(firefox.getBrowser(), is("chrome"));
assertThat(firefox.getSeleniumContainer().getImage().toString(), is("selenium/standalone-chrome-debug:2.53.0"));
assertThat(firefox.getSeleniumContainer().getImage().toString(), is("selenium/standalone-chrome-debug:4.1.1"));
assertThat(firefox.getSeleniumContainer().getPortBindings(), hasItem(PortBinding.valueOf("14444->4444")));
assertThat(firefox.getSeleniumContainer().getAwait().getResponseCode(), is(403));
assertThat(firefox.getSeleniumContainer().getAwait().getResponseCode(), is(200));
}

@Test
Expand Down
7 changes: 0 additions & 7 deletions docker/ftest-drone-custom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
7 changes: 0 additions & 7 deletions docker/ftest-drone-reporter/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
7 changes: 0 additions & 7 deletions docker/ftest-drone/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
7 changes: 0 additions & 7 deletions docker/ftest-graphene/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
6 changes: 3 additions & 3 deletions docker/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
<modelVersion>4.0.0</modelVersion>

<properties>
<version.graphene>2.1.0.Final</version.graphene>
<version.arquillian.drone>2.0.0.Final</version.arquillian.drone>
<version.selenium>2.53.1</version.selenium>
<version.graphene>3.0.0-alpha.3</version.graphene>
<version.arquillian.drone>3.0.0-alpha.4</version.arquillian.drone>
<version.selenium>4.1.2</version.selenium>
</properties>

<!-- Artifact Configuration -->
Expand Down
2 changes: 0 additions & 2 deletions kubernetes/kubernetes/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@
<dependency>
<groupId>io.sundr</groupId>
<artifactId>builder-annotations</artifactId>
<version>0.2.8</version>
<scope>compile</scope>
<optional>true</optional>
</dependency>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ public String toString() {
if (environmentConfigUrl != null) {
appendPropertyWithValue(content, ENVIRONMENT_CONFIG_URL, environmentConfigUrl);
}
if (!environmentDependencies.isEmpty()) {
if (environmentDependencies != null && !environmentDependencies.isEmpty()) {
appendPropertyWithValue(content, ENVIRONMENT_DEPENDENCIES, environmentDependencies.toString());
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ public void createEnvironment() {
try {
URL configUrl = configuration.getEnvironmentConfigUrl();
List<URL> dependencyUrls =
!configuration.getEnvironmentDependencies().isEmpty() ? configuration.getEnvironmentDependencies()
configuration.getEnvironmentDependencies() != null && !configuration.getEnvironmentDependencies().isEmpty()
? configuration.getEnvironmentDependencies()
: dependencyResolver.resolve(session);

if (configuration.isEnvironmentInitEnabled()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ private List<FileEntry> getFilesForResourcesConfiguration(Session session, Confi

if (configuration.isEnvironmentInitEnabled()) {
List<URL> dependencyUrls =
!configuration.getEnvironmentDependencies().isEmpty() ? configuration.getEnvironmentDependencies()
configuration.getEnvironmentDependencies() != null && !configuration.getEnvironmentDependencies().isEmpty()
? configuration.getEnvironmentDependencies()
: dependencyResolver.get().resolve(session);

for (URL dependencyUrl : dependencyUrls) {
Expand Down
7 changes: 0 additions & 7 deletions openshift/ftest-openshift-graphene/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,6 @@
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Expand Down
21 changes: 5 additions & 16 deletions openshift/openshift/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,9 @@
<version.javax.inject>1</version.javax.inject>
<version.jgit>4.0.0.201506090130-r</version.jgit>
<version.alpn>8.1.9.v20160720</version.alpn>
<version.selenium>3.6.0</version.selenium>
<version.graphene>2.3.1</version.graphene>
<version.selenium>4.1.2</version.selenium>
<version.graphene>3.0.0-alpha.3</version.graphene>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.jboss.arquillian.selenium</groupId>
<artifactId>selenium-bom</artifactId>
<version>${version.selenium}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.arquillian.cube</groupId>
Expand Down Expand Up @@ -152,8 +141,6 @@
<dependency>
<groupId>io.sundr</groupId>
<artifactId>builder-annotations</artifactId>
<version>0.2.8</version>
<scope>compile</scope>
<optional>true</optional>
</dependency>

Expand Down Expand Up @@ -194,12 +181,14 @@
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-support</artifactId>
<artifactId>selenium-support</artifactId>
<version>${version.selenium}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-remote-driver</artifactId>
<version>${version.selenium}</version>
<scope>provided</scope>
</dependency>
<dependency>
Expand Down
6 changes: 3 additions & 3 deletions openshift/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
<name>Arquillian Cube OpenShift Parent</name>

<properties>
<version.graphene>2.1.0.Final</version.graphene>
<version.arquillian.drone>2.0.0.Final</version.arquillian.drone>
<version.selenium>2.53.1</version.selenium>
<version.graphene>3.0.0-alpha.3</version.graphene>
<version.arquillian.drone>3.0.0-alpha.4</version.arquillian.drone>
<version.selenium>4.1.2</version.selenium>
</properties>

<modules>
Expand Down
28 changes: 20 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>org.jboss</groupId>
<artifactId>jboss-parent</artifactId>
<version>25</version>
<version>39</version>
<relativePath />
</parent>

Expand Down Expand Up @@ -68,14 +68,15 @@
</issueManagement>

<properties>
<version.arquillian_core>1.6.0.Final</version.arquillian_core>
<version.junit>4.12</version.junit>
<version.arquillian_core>1.7.0.Alpha10</version.arquillian_core>
<version.junit>4.13.1</version.junit>
<version.hamcrest>1.3</version.hamcrest>
<version.docker-java>3.2.0</version.docker-java>
<version.kubernetes_client>4.0.3</version.kubernetes_client>
<version.snakeyaml>1.25</version.snakeyaml>
<version.shrinkwrap_resolver>3.0.1</version.shrinkwrap_resolver>
<version.shrinkwrap>1.2.6</version.shrinkwrap>
<version.docker-java>3.2.13</version.docker-java>
<version.kubernetes_client>4.0.7</version.kubernetes_client>
<version.sundrio>0.80.1</version.sundrio>
<version.snakeyaml>2.0</version.snakeyaml>
<version.shrinkwrap_resolver>3.1.4</version.shrinkwrap_resolver>
<version.shrinkwrap>2.0.0-beta-1</version.shrinkwrap>
<version.mockito>1.10.19</version.mockito>
<version.fabric8_mockwebserver>0.0.17</version.fabric8_mockwebserver>
<version.descriptor.docker>1.0.0-alpha-2</version.descriptor.docker>
Expand Down Expand Up @@ -244,6 +245,15 @@
</dependency>
<!-- end::istio_dependency[] -->

<!-- Compile Only Dependencies -->
<dependency>
<groupId>io.sundr</groupId>
<artifactId>builder-annotations</artifactId>
<version>${version.sundrio}</version>
<scope>compile</scope>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.eclipse.jgit</groupId>
<artifactId>org.eclipse.jgit</artifactId>
Expand Down Expand Up @@ -458,9 +468,11 @@
<plugins>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.2</version>
</plugin>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.22.2</version>
<configuration>
<groups>${failsafe.groups}</groups>
</configuration>
Expand Down