fakeHubClient is an in-memory HubClient for exercising HubSync without gRPC.
| 17 | |
| 18 | // fakeHubClient is an in-memory HubClient for exercising HubSync without gRPC. |
| 19 | type fakeHubClient struct { |
| 20 | mu sync.Mutex |
| 21 | convID string |
| 22 | convCounter int |
| 23 | seq int64 |
| 24 | events []models.ConversationEvent |
| 25 | subCh chan models.ConversationEvent |
| 26 | appended []models.ConversationEvent |
| 27 | bindings []models.HubBinding |
| 28 | } |
| 29 | |
| 30 | func newFakeHubClient() *fakeHubClient { |
| 31 | return &fakeHubClient{convID: "conv-1", convCounter: 1, subCh: make(chan models.ConversationEvent, 16)} |
nothing calls this directly
no outgoing calls
no test coverage detected