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

Getting Windows go test -integration working #434

Open
puellanivis opened this issue Apr 22, 2021 · 2 comments
Open

Getting Windows go test -integration working #434

puellanivis opened this issue Apr 22, 2021 · 2 comments

Comments

@puellanivis
Copy link
Collaborator

puellanivis commented Apr 22, 2021

I figured, I have everything necessary to give this a shot, what could possibly go wrong? Maybe it would expose the issue with the io.Copy mentioned in #433 ? I’ve jotted down an example of some generic classes of errors below.

What assumption did we make wrong here?

client_integration_test.go:752: Getwd: wanted absolute path, got "/C:/Users/snowgirl/Work/sftp"

Intriguing, symlinks aren’t working, we likely need admin rights for symlinks in Windows:

client_integration_test.go:773: symlink C:\Users\snowgirl\AppData\Local\Temp\sftptest-readlink416952039\file C:\Users\snowgirl\AppData\Local\Temp\sftptest-readlink416952039\symlink: A required privilege is not held by the client.

Not sure how these handles are being left open:

sftp server file with handle "1" left open: C:\Users\snowgirl\AppData\Local\Temp\sftptest-readdeadlock065051590/writeTest
``̀ 

Error message doesn’t even say what file:
`̀ `
server_integration_test.go:617: C:\Windows\System32\OpenSSH\sftp.exe: exit status 1: Couldn't stat remote file: Failure

😬

server_integration_test.go:694: put: local /tmp/sftp.65b523619ba1776cc46bf73a4337dd8d remote /tmp/sftp.ae0dc63945ea2295246a74b92d609d22
server_integration_test.go:699: open /tmp/sftp.65b523619ba1776cc46bf73a4337dd8d: The system cannot find the path specified.
$ grep -r tmp
server_integration_test.go:     tmpDirRemote := "/tmp/" + randName()

Where is this weird , output coming from?

--- FAIL: TestServerPutRecursive (0.06s)
    server_integration_test.go:869: put recursive: local C:\Users\snowgirl\Work\sftp remote /tmp/sftp.27a44279ebd0fbbb08777194541b8adb
    server_integration_test.go:873: runSftpClient failed: C:\Windows\System32\OpenSSH\sftp.exe: exit status 1: Couldn't stat remote file: Failure
        , output

@drakkan
Copy link
Collaborator

drakkan commented Apr 24, 2021

@puellanivis I did some tests here we have to rewrite a lot of test cases to make them work on Windows :-(

@puellanivis
Copy link
Collaborator Author

Yeah, this is probably definitely going to end up being an epic. 😆

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants