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

Convert to connect-go based psdb driver #46

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from
Draft

Conversation

mattrobenolt
Copy link
Member

No description provided.

@@ -38,7 +39,7 @@ func TestRead_CanPeekBeforeRead(t *testing.T) {
}

cc := clientConnectionMock{
syncFn: func(ctx context.Context, in *psdbconnect.SyncRequest, opts ...grpc.CallOption) (psdbconnect.Connect_SyncClient, error) {
syncFn: func(ctx context.Context, in *connect.Request[psdbconnect.SyncRequest]) (*connect.ServerStreamForClient[psdbconnect.SyncResponse], error) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got real lost in the sauce here and gave up with the mocks. With grpc-go, the Connect_SyncClient was an interface, so it was simpler to mock, with connect-go these are a concrete type *connect.ServerStreamForClient[T any], so I'm not sure how to mock this.

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