Open certaintls opened 2 years ago
@CryptoSax I think the locket feature broke all tests. For example, locally
vscode ➜ /workspaces/shapeshifter-dispatcher/shTests/SocksTCP (main ✗) $ sh ./runAllSocksTests.sh
go build github.com/OperatorFoundation/shapeshifter-dispatcher/shTests/SocksTCP: no non-test Go files in /workspaces/shapeshifter-dispatcher/shTests/SocksTCP
SMETHODS DONE
SMETHODS DONE
SMETHODS DONE
CMETHOD Optimizer socks5 127.0.0.1:1443
CMETHODS DONE
./testSocksTCPOptimizerFirst.sh: line 30: pushd: shTests/SocksTCP: No such file or directory
sleeping
done with nap
this is the authentication method the socks server is sending: 5 9
this is the socks authentication variable: 9
10
accepted
Received an error while attempting to accept a connection:clientConfirmationCode and server copy not equal10 is the number of bytes being read
1
--- FAIL: TestSocksTCPOptimizerFirst (121.05s)
FAIL
exit status 1
FAIL github.com/OperatorFoundation/shapeshifter-dispatcher/shTests/SocksTCP 121.053s
./testSocksTCPOptimizerFirst.sh: line 32: popd: directory stack empty
Test Failed
go build github.com/OperatorFoundation/shapeshifter-dispatcher/shTests/SocksTCP: no non-test Go files in /workspaces/shapeshifter-dispatcher/shTests/SocksTCP
SMETHODS DONE
SMETHODS DONE
SMETHODS DONE
CMETHOD Optimizer socks5 127.0.0.1:1443
CMETHODS DONE
./testSocksTCPOptimizerMinimizeDialDuration.sh: line 30: pushd: shTests/SocksTCP: No such file or directory
sleeping
done with nap
this is the authentication method the socks server is sending: 5 9
this is the socks authentication variable: 9
10
accepted
Received an error while attempting to accept a connection:clientConfirmationCode and server copy not equal
You can also see the broken tests in the pipeline: https://github.com/certaintls/shapeshifter-dispatcher/runs/8201150855?check_suite_focus=true#step:5:41
Added the github action to automate the testing on Push and Pull Request. Through the work, I changed two additional things to make all the test green:
$GOPATH
in the test, they were not working. I didn't spend time understanding how exactly they failed. Because newer go can set it automatically, see https://stackoverflow.com/a/53026674/1966269 . I tested at my local running the tests manually and in the pipeline (see the link below), golang can automatically handle $GOPATH.You can see the final version of this action passed all the tests https://github.com/certaintls/shapeshifter-dispatcher/actions/runs/2765284044