-
Notifications
You must be signed in to change notification settings - Fork 49
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
Rerun suite, test, url #412
Conversation
@@ -49,6 +50,9 @@ public void setStepResult(ComparatorStepResult stepResult) { | |||
} | |||
|
|||
public List<Operation> getFilters() { | |||
if(filters == null){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it possible to pass the condition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the review ;)
Unfortunately, it is possible because the model in mongo has null when you saving empty array.
You can find more details here: discussion
@@ -52,8 +54,12 @@ | |||
private static final Type SUITE_TYPE = new TypeToken<Suite>() { | |||
}.getType(); | |||
|
|||
public void setCorrelationId(String correlationId) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we have the setter so high in the class?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed 😄
@@ -191,7 +208,7 @@ public String toString() { | |||
.toString(); | |||
} | |||
|
|||
public void setVersion(long version) { | |||
public void setVersion(Long version) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it expected that version
could be null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes,
I remember that it is strongly connected with updating version of a suite. Suite version is null during the first run of and typical run but during rerun, the suite has a version, so I needed to allow on setting empty version and set the same state like in a typical run. I didn't see a better way to set the correct suite's version during the rerun.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please also update wiki SuiteReportFeatures docs and add some screenshots (e.g. those form the ticket description) and short note of the feature?
Also please update What's New with the short description or link to the Report Features Wiki Page.
break; | ||
} | ||
} | ||
return Optional.ofNullable(urlToReturn); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just cosmetics and your implementation is perfectly fine. But you could also do this method body with streams:
return Optional.ofNullable(urlToReturn); | |
return urls.stream() | |
.filter(url -> url.getName().equals(urlName)) | |
.findFirst(); |
|
||
public class SuiteExecutionProcessorStrategy extends ProcessorStrategy { | ||
|
||
protected static final Logger logger = LoggerFactory |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Name should be all upercase LOGGER
a this is constant.
|
||
public class TestExecutionProcessorStrategy extends ProcessorStrategy { | ||
|
||
protected static final Logger logger = LoggerFactory |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Name should be all upercase LOGGER
a this is constant.
|
||
public class UrlExecutionProcessorStrategy extends ProcessorStrategy { | ||
|
||
protected static final Logger logger = LoggerFactory |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Name should be all upercase LOGGER
a this is constant.
…one/rerun-one-test # Conflicts: # CHANGELOG.md # rest-endpoint/src/main/java/com/cognifide/aet/rest/ArtifactServlet.java
…de/aet into milestone/rerun-one-test
Thank you for help with documentation and review |
CHANGELOG.md
Outdated
@@ -18,6 +18,7 @@ All notable changes to AET will be documented in this file. | |||
- [PR-396](https://github.com/Cognifide/aet/pull/396) Added horizontal scrollbar for wide pages ([#393](https://github.com/Cognifide/aet/issues/393)) | |||
- [PR-403](https://github.com/Cognifide/aet/pull/403) Conditionally passed tests can be accepted ([#400](https://github.com/Cognifide/aet/issues/400)) | |||
- [PR-387](https://github.com/Cognifide/aet/pull/387) Set max allowed page screenshot height to 35k pixels. | |||
- [PR-412](https://github.com/Cognifide/aet/pull/412) ([PR-336](https://github.com/Cognifide/aet/pull/336), [PR-337](https://github.com/Cognifide/aet/pull/337), [PR-395](https://github.com/Cognifide/aet/pull/395)) - Added rerun functionality for suite, test and url |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@plutasnyy Please move this entry to "Unreleased" section
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done 😃
Tested (/) |
Description
This PR provide you the functionality to rerun the whole suite - it runs in the same way like typical suite run, only test or url rerun - rerun part of suite work in a different way, after rerun, artifacts in your suite will be overwritten and aet doesn't create a new version of the suite.
The new way to run a test for page requires changes in the cleaner. The cleaner should remove overwritten artifacts- we don't want rubbish in our database. Functionality for the cleaner is in this PR
Motivation and Context
It would be a nice improvement for users
Screenshots (if appropriate):
Types of changes
Checklist:
I hereby agree to the terms of the AET Contributor License Agreement.