Skip to content

Refactor transport tests #1450

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

Closed

Conversation

onee-only
Copy link
Contributor

This PR mainly introduces fixes for #1218 and #1445.
Other changes are minor enhancements for test code.

@onee-only onee-only force-pushed the refactor-transport-tests branch from 3a6fc8e to 7a34665 Compare March 8, 2025 03:33
@onee-only
Copy link
Contributor Author

onee-only commented Mar 8, 2025

Even though the test doesn't support windows, I had to make it compilable for windows. I've manually tested it on my windows PC and it is properly killing daemon.

if runtime.GOOS == "windows" {
s.T().Skip(`git for windows has issues with write operations through git:// protocol.
See https://github.com/git-for-windows/git/issues/907`)
}

@pjbgf
Copy link
Member

pjbgf commented Mar 15, 2025

@onee-only thank you for looking into this. Please note that plumbing/transport is being refactored and the latest version lives in the v6-transport branch. Please rebase and target that branch instead.

@onee-only onee-only force-pushed the refactor-transport-tests branch from 7a34665 to eb61216 Compare March 15, 2025 13:42
@onee-only onee-only changed the base branch from main to v6-transport March 15, 2025 13:42
@onee-only
Copy link
Contributor Author

onee-only commented Mar 15, 2025

@pjbgf Thanks for telling me that I wasn't targeting the appropriate branch.

I've rebased it to v6-transport. However, since the tests are properly executed, tests are failing with latest changes on this branch.
I tried to dig into it, but I think this is out of my hand.

@onee-only
Copy link
Contributor Author

FYI, ReceivePackSuite in transport/file stalls when it executes TestSendPackAddDeleteReference.
I suspect it is related to gooutines created in (c *command) Start(), which is in transport/file/client.go

@onee-only
Copy link
Contributor Author

onee-only commented Apr 15, 2025

@pjbgf It seems that this PR has conflicting changes with #1496.
I believe at least 25e63f8 is necessary for v6-transport as this as it exposes hidden failing tests.

@pjbgf
Copy link
Member

pjbgf commented Apr 15, 2025

@onee-only apologies for the wasted effort here. @aymanbagabas have been working on several changes across transport, so making changes to tests that touch any of that is a bit problematic. Perhaps it is easier to just revisit this once #1496 is merged?

@onee-only
Copy link
Contributor Author

I found out that #1496 introduces partial fix for #1445 by changing suites on git package.
Since 25e63f8 is mainly about "inheriting the test suite properly", I think we can just abondon this commit and make #1496 fix the test suites in transport/xxx package.
It'll be more convinient for @aymanbagabas to fix the failing tests in the same PR.

About #1218, I didn't test it but fix for it also seems to be introduced in #1496.

So I think I'll close this PR and make new one with small changes when #1496 is merged.
@pjbgf What are your thoughts?

@pjbgf
Copy link
Member

pjbgf commented Apr 16, 2025

@onee-only that sounds good, thanks for that. 🙇

@onee-only
Copy link
Contributor Author

Alright. closing the PR.

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

Successfully merging this pull request may close these issues.

2 participants