mirror of
https://github.com/lorsanstand/HomeOps-Hub.git
synced 2026-06-19 16:45:15 +03:00
refactor: change structure project
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
package agent_service
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/lorsanstand/HomeOps-Hub/shared/domain"
|
||||
)
|
||||
|
||||
type CollectorMock struct {
|
||||
host domain.HostInfo
|
||||
caps []domain.Capability
|
||||
}
|
||||
|
||||
func (c *CollectorMock) GatherInfoSystem() (domain.HostInfo, []domain.Capability) {
|
||||
return c.host, c.caps
|
||||
}
|
||||
|
||||
type ConnectionMock struct {
|
||||
regAgentErr error
|
||||
regResp domain.RegisterAgentResponse
|
||||
}
|
||||
|
||||
func (c *ConnectionMock) RegisterAgent(ctx context.Context, RegisterData domain.RegisterAgentRequest) (domain.RegisterAgentResponse, error) {
|
||||
return c.regResp, c.regAgentErr
|
||||
}
|
||||
Reference in New Issue
Block a user