mirror of
https://github.com/fleetdm/fleet
synced 2026-05-17 05:58:40 +00:00
For #26218 This is a dev helper feature (since it will be implemented in fleetdm.com). It fixes the issue of stale PubSub topics. Having stale PubSub topics around may cause extra traffic/errors on dev server. - [x] Manual QA for all new/changed functionality
23 lines
722 B
Go
23 lines
722 B
Go
package mock
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/fleetdm/fleet/v4/server/mdm/android"
|
|
"google.golang.org/api/androidmanagement/v1"
|
|
)
|
|
|
|
func (p *Proxy) InitCommonMocks() {
|
|
p.EnterpriseDeleteFunc = func(ctx context.Context, enterpriseID string) error {
|
|
return nil
|
|
}
|
|
p.SignupURLsCreateFunc = func(callbackURL string) (*android.SignupDetails, error) {
|
|
return &android.SignupDetails{}, nil
|
|
}
|
|
p.EnterprisesCreateFunc = func(ctx context.Context, req android.ProxyEnterprisesCreateRequest) (string, string, error) {
|
|
return "enterpriseName", "projects/project/topics/topic", nil
|
|
}
|
|
p.EnterprisesPoliciesPatchFunc = func(enterpriseID string, policyName string, policy *androidmanagement.Policy) error {
|
|
return nil
|
|
}
|
|
}
|