-
Notifications
You must be signed in to change notification settings - Fork 280
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
Add failing test for SSH clone #478
Conversation
Cloning with an ssh URL results in error "Unsupported URL protocol" which is the result of a libgit2 check if SSH is not enabled.
SSH used to work, so this is a regression 😦 While I like the idea of having a test like this, there are several reasons it could fail which have nothing to do with the framework. Also, the build server may not even be set up with an SSH key. Perhaps this test could be disabled by default and then manually enabled - or perhaps the logic depends on an environment variable to be present. I think a better permanent test would be to assert that git_libgit2_features returns with the |
👍 Will rewrite it then and find a test file where it suites in. |
You can disable the test with |
Yeah, it seems that |
I've worked with the build scripts and cmake a bit so I can look into this issue. |
I would also love to work on this but have little hope. I tried adding |
The libgit2 cmake build will disable SSH support if it doesn't find the libraries, which may be what's going on here. Are you seeing this when building for Mac, iOS or both? |
Both as Mac is the test target and my iOS app also fails. Afaik the Mac build uses system OpenSSH and the iOS app depends on the OpenSSH iOS build. |
@phatblat I fixed the build and enabled SSH support. I also refactored the test to test for the correct error (SSH credentials not there). |
Fantastic! 🎈 I'll test this out later this evening. I have an idea for getting those SSH credentials working. |
Superb!! 🎉 On Tuesday, July 7, 2015, Ben Chatelain [email protected] wrote:
|
@phatblat Did you have any chance to get to the tests or maybe share your approach? |
Sorry, got tied up the last couple evenings. I started adding some logic to pick up the SSH keys from I presume these values are defined on the GitHub build server. I defined them as above and ran this test on my Mac. So, SSH is working fine on the Mac side - without these changes. |
It's been challenging validating this change on iOS as my client app builds with Xcode 7 but I'm not able to build ObjectiveGit from source with 7. However, I built this branch with 6.4 and copied over the .framework and the This looks like progress, but I'd like to do some deeper validation because this change forces |
I think this may be the real fix: phatblat/objective-git@aed2cc3. I misspelled |
I can verify it, my app still runs on Xcode 6.4. Will try it out today. If it fixes the issue, I will cherry pick and rebase this branch. |
Also check out #483 to see if that works for you. |
Closing in favour of #483 |
Cloning with an ssh URL results in error
Unsupported URL protocol
which is the result of alibgit2
check if SSH is enabled. It seems that SSH is not enabled forobjective-git
, although theGIT_SSH
flag is set.Is this the expected behaviour?