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

selenium upgraded to 3.8.1, guava upgraded to 23.6-jre #209

Merged
merged 12 commits into from
Jan 30, 2018
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ All notable changes to AET will be documented in this file.
## Unreleased
**List of changes that are finished but not yet released in any final version.**

- [PR-209](https://github.com/Cognifide/aet/pull/209) Selenium upgraded to 3.8.1. Guava upgraded to 23.6-jre

## Version 2.1.4
- [PR-184](https://github.com/Cognifide/aet/pull/184) Fixed xUnit generation NPE when stepResult is missing
- [PR-183](https://github.com/Cognifide/aet/pull/183) Fixed ambiguous messages from AET API ([#161](https://github.com/Cognifide/aet/issues/161) and [#165](https://github.com/Cognifide/aet/issues/161))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;

/**
* @author lukasz.wieczorek
Expand Down Expand Up @@ -49,7 +49,7 @@ public void setMessage(String message) {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("message", message)
.add("success", success)
.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;

/**
Expand Down Expand Up @@ -71,7 +71,7 @@ public enum Phase {

@Override
public String toString() {
return Objects.toStringHelper(this).add("phase", phase).add("description", description)
return MoreObjects.toStringHelper(this).add("phase", phase).add("description", description)
.toString();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import com.cognifide.aet.communication.api.JobStatus;
import com.cognifide.aet.communication.api.ProcessingError;
import com.cognifide.aet.communication.api.metadata.Url;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;

/**
Expand Down Expand Up @@ -111,7 +111,7 @@ public String getTestName() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("testName", testName)
.add("urlAfterCollect", urlAfterCollect)
.add("status", status)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import com.cognifide.aet.communication.api.JobStatus;
import com.cognifide.aet.communication.api.ProcessingError;
import com.cognifide.aet.communication.api.metadata.Comparator;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;

/**
Expand Down Expand Up @@ -97,7 +97,7 @@ public Integer getStepIndex() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("urlName", urlName)
.add("testName", testName)
.add("stepIndex", stepIndex)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.messages;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;

public class FatalErrorMessage implements BasicMessage {

Expand Down Expand Up @@ -45,7 +45,7 @@ public MessageType getMessageType() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("message", message)
.add("correlationId", correlationId)
.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.messages;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableList;
import java.util.ArrayList;
import java.util.List;
Expand Down Expand Up @@ -65,7 +65,7 @@ public MessageType getMessageType() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("correlationId", correlationId)
.add("status", status)
.add("errors", errors)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
package com.cognifide.aet.communication.api.messages;

import com.cognifide.aet.communication.api.ProcessingError;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;

public class ProcessingErrorMessage implements BasicMessage {

Expand Down Expand Up @@ -46,7 +46,7 @@ public MessageType getMessageType() {

@Override
public String toString() {
return Objects.toStringHelper(this).add("correlationId", correlationId)
return MoreObjects.toStringHelper(this).add("correlationId", correlationId)
.add("processingError", processingError).toString();

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.Joiner;
import com.google.common.base.MoreObjects;
import com.google.common.base.Objects;
import com.google.common.collect.ImmutableList;
import java.util.ArrayList;
Expand Down Expand Up @@ -88,7 +89,7 @@ public String getName() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("type", type)
.add("filters", filters)
.add("parameters", parameters)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableMap;
import java.io.Serializable;
import java.util.Collections;
Expand Down Expand Up @@ -56,7 +56,7 @@ public Map<String, String> getParameters() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("type", type)
.add("parameters", parameters)
.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
*/
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.MoreObjects;
import com.google.common.base.Objects;
import java.util.HashSet;
import java.util.Set;
Expand Down Expand Up @@ -122,7 +123,7 @@ public void setStatistics(Statistics statistics) {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("index", index)
.add("type", type)
.add("name", name)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import java.io.Serializable;
Expand Down Expand Up @@ -68,7 +68,7 @@ public List<String> getErrors() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("status", getStatusName())
.add("artifactId", getArtifactId())
.add("errors", getErrors())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.cognifide.aet.communication.api.metadata.gson.MapSerializer;
import com.cognifide.aet.communication.api.metadata.gson.TimestampSerializer;
import com.cognifide.aet.communication.api.util.ValidatorProvider;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.base.Predicate;
import com.google.common.collect.FluentIterable;
import com.google.gson.Gson;
Expand Down Expand Up @@ -182,7 +182,7 @@ public int hashCode() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("correlationId", correlationId)
.add("company", company)
.add("project", project)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;
Expand Down Expand Up @@ -99,7 +99,7 @@ public int hashCode() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("name", name)
.toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
package com.cognifide.aet.communication.api.metadata;

import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
Expand Down Expand Up @@ -100,7 +100,7 @@ public void setCollectionStats(Statistics collectionStats) {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("name", name)
.add("url", url)
.add("domain", domain)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@


import com.cognifide.aet.vs.DBKey;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;

/**
* POJO used to pass properties to Collectors/Comparators on worker.
Expand Down Expand Up @@ -54,7 +54,7 @@ public String getPatternId() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("company", company)
.add("project", project)
.add("patternId", patternId)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
package com.cognifide.aet.job.api.comparator;

import com.cognifide.aet.job.api.StepProperties;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;

public class ComparatorProperties extends StepProperties {

Expand All @@ -37,7 +37,7 @@ public String getCollectedId() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("collectedId", collectedId)
.add("company", getCompany())
.add("project", getProject())
Expand Down
2 changes: 1 addition & 1 deletion client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>15.0</version>
<version>23.6-jre</version>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's upgrade guava also in aet-features.xml file.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/osgi-dependencies/aet-features.xml is recently added to gitignore. Is this expected? That's why my change is not in this PR.

</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.cognifide.aet.cleaner.validation.CleanerSchedulerValidator;
import com.cognifide.aet.validation.ValidationResultBuilder;
import com.cognifide.aet.validation.ValidationResultBuilderFactory;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.collect.ImmutableMap;
import java.util.Map;
import java.util.UUID;
Expand Down Expand Up @@ -179,7 +179,7 @@ private String registerCleaningJob() throws SchedulerException {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("schedule", schedule)
.add("keepNVersions", keepNVersions)
.add("removeOlderThan", removeOlderThan)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
package com.cognifide.aet.cleaner.processors.exchange;

import com.cognifide.aet.vs.DBKey;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import java.io.Serializable;

public class MessageBody<T extends Serializable> implements Serializable {
Expand All @@ -42,7 +42,7 @@ public DBKey getDbKey() {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("data", data)
.add("dbKey", dbKey)
.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
package com.cognifide.aet.cleaner.processors.filters;

import com.cognifide.aet.vs.DBKey;
import com.google.common.base.Objects;
import com.google.common.base.MoreObjects;
import com.google.common.base.Predicate;
import org.apache.commons.lang3.StringUtils;

Expand Down Expand Up @@ -46,7 +46,7 @@ private boolean companyMatches(DBKey dbKey) {

@Override
public String toString() {
return Objects.toStringHelper(this)
return MoreObjects.toStringHelper(this)
.add("companyFilter", companyFilter)
.add("projectFilter", projectFilter)
.toString();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,13 +107,4 @@ public void setParameters_whenNoParamsIsProvided_thenExceptionIsThrown()
tested.setParameters(params);
}

@Test
public void collect_whenValidXpathParamIsProvided_elementIsClicked()
throws ProcessingException, ParametersException {
setupParams(PARAM_TIMEOUT_VALUE, PARAM_XPATH_VALUE, null);
when(elementToClick.isDisplayed()).thenReturn(true);
tested.setParameters(params);
tested.collect();
verify(webDriver, atLeast(1)).findElement(By.xpath(PARAM_XPATH_VALUE));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -88,24 +88,4 @@ public void setParameters_CssAndXpathAreNotPassed_ValidationPassedUnsuccessfuly(
throws ParametersException {
tested.setParameters(params);
}

@Test
public void hideElement_ValidXPathIsProvided_WebDriverFindElementsMethodIsCalledOnce()
throws ProcessingException, ParametersException {
when(params.containsKey(PARAM_XPATH)).thenReturn(true);
when(params.get(PARAM_XPATH)).thenReturn(PARAM_XPATH_VALUE);
tested.setParameters(params);
tested.collect();
verify(webDriver, atLeast(1)).findElement(By.xpath(PARAM_XPATH_VALUE));
}

@Test
public void hideElement_ValidCssIsProvided_WebDriverFindElementsMethodIsCalledOnce()
throws ProcessingException, ParametersException {
when(params.containsKey(PARAM_CSS)).thenReturn(true);
when(params.get(PARAM_CSS)).thenReturn(PARAM_CSS_VALUE);
tested.setParameters(params);
tested.collect();
verify(webDriver, atLeast(1)).findElement(By.cssSelector(PARAM_CSS_VALUE));
}
}
Loading