GH-3247: Fix SftpSession.exists for error code (#3248)
* GH-3247: Fix `SftpSession.exists` for error code Fixes https://github.com/spring-projects/spring-integration/issues/3247 When there is no path on the SFTP server, a `ChannelSftp.SSH_FX_NO_SUCH_FILE` error is returned in the thrown `SftpException`. * Fix `SftpSession.exists()` to check for the `SSH_FX_NO_SUCH_FILE` to return `false` and re-throw an exception otherwise * Add mock test for `SftpSession.exists()` * Add `org.mockito.AdditionalMatchers` to `checkstyle.xml` exclusions **Cherry-pick to 5.2.x & 5.1.x** * * Add exists tests against Mina embedded server
This commit is contained in:
@@ -84,6 +84,7 @@
|
||||
org.mockito.BDDMockito.*,
|
||||
org.mockito.AdditionalAnswers.*,
|
||||
org.mockito.ArgumentMatchers.*,
|
||||
org.mockito.AdditionalMatchers.*,
|
||||
org.springframework.integration.gemfire.config.xml.ParserTestUtil.*,
|
||||
org.springframework.integration.test.mock.MockIntegration.*,
|
||||
org.springframework.integration.test.util.TestUtils.*,
|
||||
|
||||
Reference in New Issue
Block a user