-
Notifications
You must be signed in to change notification settings - Fork 15
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
Remove dedicated StringUtils class #249
Conversation
StringUtils.isStringEmpty(actionName) | ||
|| actionName.equals(INIT_STRING) | ||
) { | ||
if (StringUtils.isNotBlank(actionName) || actionName.equals(INIT_STRING)) { |
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.
in the old version it is isStringEmpty(), so isNotBlank() will result in another behaviour
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, indeed that was wrong. Fixed that.
final String user = PropertyManager.getProperty(proxyType + ".proxyUser"); | ||
if (org.apache.commons.lang3.StringUtils.isNotEmpty(user)) { | ||
final String user = PROPERTY_MANAGER.getProperty(proxyType + ".proxyUser"); | ||
if (StringUtils.isNotBlank(user)) { |
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.
Changed behaviour. Was isNotEmpty
previously. Sanity Check: Intended?
(Same for two more calls below.)
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 don't want to use spaces " "
as user
. Before it was possible.
@@ -472,7 +473,7 @@ public void testT07_signMessage() { | |||
public void testT08_sendAndWaitForMessageWithoutAttachement_SubjectSenderRecipient() throws Exception { | |||
|
|||
final String subject = "testT08_sendAndWaitForMessageWithoutAttachement_SubjectSenderRecipient" | |||
+ StringUtils.getRandomStringWithLength(5); | |||
+ RandomStringUtils.random(5, true, false); |
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.
Changed behaviour: Old method would only generate [A-Z]^length
. (JavaDoc seems to be wrong?)
Sanity Check: Intended?
... The old behaviour was like this even in the first commit, so the documented result might have been the expected one to begin with...
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.
It doesn't matter if the test uses a random string with or without a subset of [A-Za-z]
.
Well, there is no need to use a random string in any MailConnector test method because the subject is already unique by the method name.
Description
This PR removes the very outdated Testerra
StringUtils
class and its unit tests. The usage was only internal and it was not documentated. If needed the calls were replaced by the Apache commons libStringUtils
.Type of change
Please delete options that are not relevant.
Checklist: