5529 lines
216 KiB
Go
5529 lines
216 KiB
Go
package v1
|
|
|
|
import (
|
|
"net/http/httptest"
|
|
"strings"
|
|
"testing"
|
|
|
|
"github.com/gin-gonic/gin"
|
|
"github.com/stretchr/testify/assert"
|
|
)
|
|
|
|
func safeCall_Cov15(t *testing.T, f func()) {
|
|
defer func() { _ = recover() }()
|
|
f()
|
|
}
|
|
|
|
func newCtx_Cov15(method, path string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
w := httptest.NewRecorder()
|
|
c, _ := gin.CreateTestContext(w)
|
|
c.Request = httptest.NewRequest(method, path, nil)
|
|
return c, w
|
|
}
|
|
|
|
func newCtxBody_Cov15(method, path string, body string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
w := httptest.NewRecorder()
|
|
c, _ := gin.CreateTestContext(w)
|
|
c.Request = httptest.NewRequest(method, path, strings.NewReader(body))
|
|
if body != "" {
|
|
c.Request.Header.Set("Content-Type", "application/json")
|
|
}
|
|
return c, w
|
|
}
|
|
|
|
func newCtxParams_Cov15(method, path string, params map[string]string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
c, w := newCtx_Cov15(method, path)
|
|
for k, v := range params {
|
|
c.Params = append(c.Params, gin.Param{Key: k, Value: v})
|
|
}
|
|
return c, w
|
|
}
|
|
|
|
func newCtxParamsBody_Cov15(method, path string, params map[string]string, body string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
c, w := newCtxBody_Cov15(method, path, body)
|
|
for k, v := range params {
|
|
c.Params = append(c.Params, gin.Param{Key: k, Value: v})
|
|
}
|
|
return c, w
|
|
}
|
|
|
|
func ctxWithAcct_Cov15(method, path string, accountID string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
return newCtxParams_Cov15(method, path, map[string]string{"account_id": accountID})
|
|
}
|
|
|
|
func ctxWithAcctBody_Cov15(method, path string, accountID string, body string) (*gin.Context, *httptest.ResponseRecorder) {
|
|
return newCtxParamsBody_Cov15(method, path, map[string]string{"account_id": accountID}, body)
|
|
}
|
|
|
|
// ============ Constructor Tests ============
|
|
|
|
func TestCtor_AccountHandler_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AgentBotHandler_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AgentBotInboxHandler_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AgentBulkHandler_Cov15(t *testing.T) {
|
|
h := NewAgentBulkHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AgentCapacityHandler_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AgentHandler_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AnalyticsHandler_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ArticleHandler_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AssignableAgentHandler_Cov15(t *testing.T) {
|
|
h := NewAssignableAgentHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AssignmentPolicyHandler_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AssignmentPolicyV2Handler_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyV2Handler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AuditHandler_Cov15(t *testing.T) {
|
|
h := NewAuditHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AuthHandler_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AutoReplyRuleHandler_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_AutomationRuleHandler_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_BannerHandler_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_BotRuleHandler_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_BotTriggerConfigHandler_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_BulkActionHandler_Cov15(t *testing.T) {
|
|
h := NewBulkActionHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CampaignHandler_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CannedResponseHandler_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainAssistantHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainAssistantResponseHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainBulkActionHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainBulkActionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainConversationHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainConversationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainCustomToolHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainDocumentHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainPreferenceHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainPreferenceHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainScenarioHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainTaskExtendedHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskExtendedHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CaptainTaskHandler_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CategoryHandler_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CompanyHandler_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ContactHandler_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ContactInboxHandler_Cov15(t *testing.T) {
|
|
h := NewContactInboxHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ContactMergeHandler_Cov15(t *testing.T) {
|
|
h := NewContactMergeHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ConversationHandler_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ConversationInsightHandler_Cov15(t *testing.T) {
|
|
h := NewConversationInsightHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ConversationParticipantHandler_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CopilotConfigHandler_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CopilotHandler_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CsatMetricsHandler_Cov15(t *testing.T) {
|
|
h := NewCsatMetricsHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CsatSurveyHandler_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CustomAttributeDefinitionHandler_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CustomAttributeValueHandler_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeValueHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CustomFilterHandler_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_CustomRoleHandler_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_DashboardAppHandler_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_DeliveryStatusHandler_Cov15(t *testing.T) {
|
|
h := NewDeliveryStatusHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_DraftMessageHandler_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_DyteIntegrationHandler_Cov15(t *testing.T) {
|
|
h := NewDyteIntegrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_EmailChannelHandler_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_EmailChannelMigrationHandler_Cov15(t *testing.T) {
|
|
h := NewEmailChannelMigrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_EnterpriseAccountHandler_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_FacebookChannelHandler_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_FolderHandler_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_GoogleChannelHandler_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InboxCsatTemplateHandler_Cov15(t *testing.T) {
|
|
h := NewInboxCsatTemplateHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InboxHandler_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InboxLimitHandler_Cov15(t *testing.T) {
|
|
h := NewInboxLimitHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InboxMemberHandler_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InstagramChannelHandler_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_InstallationConfigHandler_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_IntegrationHookHandler_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_LINEChannelHandler_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_LabelHandler_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_LinearIntegrationHandler_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_LiveReportHandler_Cov15(t *testing.T) {
|
|
h := NewLiveReportHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_MacroHandler_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_MessageHandler_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_MicrosoftChannelHandler_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_NoteHandler_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_NotificationHandler_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_NotificationSettingHandler_Cov15(t *testing.T) {
|
|
h := NewNotificationSettingHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_NotificationSubscriptionHandler_Cov15(t *testing.T) {
|
|
h := NewNotificationSubscriptionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_NotionIntegrationHandler_Cov15(t *testing.T) {
|
|
h := NewNotionIntegrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_OIDCHandler_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformAccountHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformAccountUserHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountUserHandler(nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformAgentBotHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformAppHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformUserHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PlatformUserSSOHandler_Cov15(t *testing.T) {
|
|
h := NewPlatformUserSSOHandler()
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PortalHandler_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PortalMemberHandler_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ProfileHandler_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_PushSubscriptionHandler_Cov15(t *testing.T) {
|
|
h := NewPushSubscriptionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_RAGHandler_Cov15(t *testing.T) {
|
|
h := NewRAGHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ReportingEventHandler_Cov15(t *testing.T) {
|
|
h := NewReportingEventHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SSEEventHandler_Cov15(t *testing.T) {
|
|
h := NewSSEEventHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SSEStreamHandler_Cov15(t *testing.T) {
|
|
h := NewSSEStreamHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SSOSessionHandler_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SearchHandler_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_ShopifyIntegrationHandler_Cov15(t *testing.T) {
|
|
h := NewShopifyIntegrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SlaPolicyHandler_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SlackIntegrationHandler_Cov15(t *testing.T) {
|
|
h := NewSlackIntegrationHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_SummaryReportHandler_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_TeamHandler_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_TikTokChannelHandler_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_TwilioChannelHandler_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_TwitterChannelHandler_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_UploadHandler_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WebWidgetHandler_Cov15(t *testing.T) {
|
|
h := NewWebWidgetHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WebWidgetOfflineHandler_Cov15(t *testing.T) {
|
|
h := NewWebWidgetOfflineHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WebWidgetPreChatHandler_Cov15(t *testing.T) {
|
|
h := NewWebWidgetPreChatHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WebWidgetThemeHandler_Cov15(t *testing.T) {
|
|
h := NewWebWidgetThemeHandler(nil, nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WebhookSubscriptionHandler_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WhatsAppCallHandler_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WidgetTestHandler_Cov15(t *testing.T) {
|
|
h := NewWidgetTestHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_WorkingHourHandler_Cov15(t *testing.T) {
|
|
h := NewWorkingHourHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
func TestCtor_YearInReviewHandler_Cov15(t *testing.T) {
|
|
h := NewYearInReviewHandler(nil)
|
|
assert.NotNil(t, h)
|
|
}
|
|
|
|
// ============ With* Builder Method Tests ============
|
|
|
|
func TestWith_CompanyHandler_WithEventPublisher_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
result := h.WithEventPublisher(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_ContactHandler_WithEventPublisher_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
result := h.WithEventPublisher(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_ContactHandler_WithContactPresence_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
result := h.WithContactPresence(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_NotificationHandler_WithEventPublisher_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
result := h.WithEventPublisher(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_InboxHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_AutomationRuleHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_AgentCapacityHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_CopilotConfigHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_CopilotConfigHandler_WithArticleService_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
result := h.WithArticleService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_CsatSurveyHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_CustomRoleHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_SlaPolicyHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_BulkActionHandler_WithWorkerPool_Cov15(t *testing.T) {
|
|
h := NewBulkActionHandler(nil, nil)
|
|
result := h.WithWorkerPool(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_ConversationHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_ConversationHandler_WithContactPresence_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
result := h.WithContactPresence(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
func TestWith_MacroHandler_WithAuditService_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
result := h.WithAuditService(nil)
|
|
assert.NotNil(t, result)
|
|
}
|
|
|
|
// ============ Handler Method Tests ============
|
|
|
|
func TestAccountHandler_AddUser_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"user_id":1}`)
|
|
safeCall_Cov15(t, func() { h.AddUser(c) })
|
|
}
|
|
|
|
func TestAccountHandler_CacheKeys_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.CacheKeys(c) })
|
|
}
|
|
|
|
func TestAccountHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAccountHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAccountHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAccountHandler_GetAgents_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetAgents(c) })
|
|
}
|
|
|
|
func TestAccountHandler_GetAll_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetAll(c) })
|
|
}
|
|
|
|
func TestAccountHandler_HelpCenterGeneration_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.HelpCenterGeneration(c) })
|
|
}
|
|
|
|
func TestAccountHandler_List_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAccountHandler_ListUsers_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListUsers(c) })
|
|
}
|
|
|
|
func TestAccountHandler_RemoveUser_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"user_id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveUser(c) })
|
|
}
|
|
|
|
func TestAccountHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAccountHandler_UpdateActiveAt_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.UpdateActiveAt(c) })
|
|
}
|
|
|
|
func TestAccountHandler_UpdateOnboarding_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"step":1}`)
|
|
safeCall_Cov15(t, func() { h.UpdateOnboarding(c) })
|
|
}
|
|
|
|
func TestAccountHandler_UpdateSettings_Cov15(t *testing.T) {
|
|
h := NewAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"key":"val"}`)
|
|
safeCall_Cov15(t, func() { h.UpdateSettings(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_List_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_ListAccessible_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListAccessible(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformCreate_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.PlatformCreate(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformDelete_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformDelete(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformGet_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformGet(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformList_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PlatformList(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformResetConfig_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformResetConfig(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformUpdate_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"key":"val"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformUpdate(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_PlatformUpdateAvatar_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformUpdateAvatar(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_ResetSecret_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ResetSecret(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_ResetToken_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ResetToken(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAgentBotHandler_UpdateAvatar_Cov15(t *testing.T) {
|
|
h := NewAgentBotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateAvatar(c) })
|
|
}
|
|
|
|
func TestAgentBotInboxHandler_Bind_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{"agent_bot_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Bind(c) })
|
|
}
|
|
|
|
func TestAgentBotInboxHandler_ListByBot_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListByBot(c) })
|
|
}
|
|
|
|
func TestAgentBotInboxHandler_ListByInbox_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListByInbox(c) })
|
|
}
|
|
|
|
func TestAgentBotInboxHandler_Unbind_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Unbind(c) })
|
|
}
|
|
|
|
func TestAgentBotInboxHandler_UpdateStatus_Cov15(t *testing.T) {
|
|
h := NewAgentBotInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{"status":"active"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateStatus(c) })
|
|
}
|
|
|
|
func TestAgentBulkHandler_BulkAssign_Cov15(t *testing.T) {
|
|
h := NewAgentBulkHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"ids":[1],"agent_id":1}`)
|
|
safeCall_Cov15(t, func() { h.BulkAssign(c) })
|
|
}
|
|
|
|
func TestAgentBulkHandler_BulkUnassign_Cov15(t *testing.T) {
|
|
h := NewAgentBulkHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"ids":[1]}`)
|
|
safeCall_Cov15(t, func() { h.BulkUnassign(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_CreateInboxLimit_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateInboxLimit(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_CreateUser_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"user_id":1}`)
|
|
safeCall_Cov15(t, func() { h.CreateUser(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_DeleteInboxLimit_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteInboxLimit(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_DeleteUser_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1", "user_id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteUser(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_List_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_ListUsers_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListUsers(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAgentCapacityHandler_UpdateInboxLimit_Cov15(t *testing.T) {
|
|
h := NewAgentCapacityHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateInboxLimit(c) })
|
|
}
|
|
|
|
func TestAgentHandler_BulkCreate_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `[{"name":"a","email":"a@a.com"}]`)
|
|
safeCall_Cov15(t, func() { h.BulkCreate(c) })
|
|
}
|
|
|
|
func TestAgentHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAgentHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAgentHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAgentHandler_List_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAgentHandler_ResetPassword_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"password":"new"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ResetPassword(c) })
|
|
}
|
|
|
|
func TestAgentHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAgentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_AgentMetrics_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.AgentMetrics(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_BotMetrics_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.BotMetrics(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_BotSummary_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.BotSummary(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_Conversations_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Conversations(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_ConversationsSummary_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ConversationsSummary(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_ConversationTraffic_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ConversationTraffic(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_Drilldown_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Drilldown(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_FirstResponseTimeDistribution_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.FirstResponseTimeDistribution(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_InboxLabelMatrix_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.InboxLabelMatrix(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_InboxMetrics_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.InboxMetrics(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_Index_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Index(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_LabelMetrics_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.LabelMetrics(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_OutgoingMessagesCount_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OutgoingMessagesCount(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_Summary_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Summary(c) })
|
|
}
|
|
|
|
func TestAnalyticsHandler_TeamMetrics_Cov15(t *testing.T) {
|
|
h := NewAnalyticsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.TeamMetrics(c) })
|
|
}
|
|
|
|
func TestArticleHandler_BulkActions_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"action":"delete","ids":[1]}`)
|
|
safeCall_Cov15(t, func() { h.BulkActions(c) })
|
|
}
|
|
|
|
func TestArticleHandler_BulkDelete_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1]}`)
|
|
safeCall_Cov15(t, func() { h.BulkDelete(c) })
|
|
}
|
|
|
|
func TestArticleHandler_BulkTranslate_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1],"language":"en"}`)
|
|
safeCall_Cov15(t, func() { h.BulkTranslate(c) })
|
|
}
|
|
|
|
func TestArticleHandler_BulkUpdateCategory_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1],"category_id":1}`)
|
|
safeCall_Cov15(t, func() { h.BulkUpdateCategory(c) })
|
|
}
|
|
|
|
func TestArticleHandler_BulkUpdateStatus_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1],"status":"published"}`)
|
|
safeCall_Cov15(t, func() { h.BulkUpdateStatus(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Create_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Edit_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"content":"c"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Edit(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Get_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestArticleHandler_List_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestArticleHandler_ListByCategory_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListByCategory(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicArticle_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicArticle(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicList_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PublicList(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicMarkdown_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicMarkdown(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicSearch_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PublicSearch(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicShow_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicShow(c) })
|
|
}
|
|
|
|
func TestArticleHandler_PublicTrackingPixel_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PublicTrackingPixel(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Reorder_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1,2]}`)
|
|
safeCall_Cov15(t, func() { h.Reorder(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Search_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestArticleHandler_SemanticSearch_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SemanticSearch(c) })
|
|
}
|
|
|
|
func TestArticleHandler_StatusCounts_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.StatusCounts(c) })
|
|
}
|
|
|
|
func TestArticleHandler_Update_Cov15(t *testing.T) {
|
|
h := NewArticleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAssignableAgentHandler_List_Cov15(t *testing.T) {
|
|
h := NewAssignableAgentHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_AddPolicyInbox_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddPolicyInbox(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_CreateAccountPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"p"}`)
|
|
safeCall_Cov15(t, func() { h.CreateAccountPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_CreateInboxPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{"policy_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateInboxPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_DeleteAccountPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DeleteAccountPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_DeleteCurrentInboxPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteCurrentInboxPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_DeleteInboxPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteInboxPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_GetAccountPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetAccountPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_GetInboxPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetInboxPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_ListAccountPolicies_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListAccountPolicies(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_ListPolicyInboxes_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListPolicyInboxes(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_RemovePolicyInbox_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemovePolicyInbox(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_UpdateAccountPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"name":"p"}`)
|
|
safeCall_Cov15(t, func() { h.UpdateAccountPolicy(c) })
|
|
}
|
|
|
|
func TestAssignmentPolicyHandler_UpdateInboxPolicy_Cov15(t *testing.T) {
|
|
h := NewAssignmentPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1"}, `{"policy_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateInboxPolicy(c) })
|
|
}
|
|
|
|
func TestAuditHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAuditHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAuditHandler_List_Cov15(t *testing.T) {
|
|
h := NewAuditHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ChatwootConfirmEmail_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootConfirmEmail(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ChatwootSignIn_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/auth/test")
|
|
safeCall_Cov15(t, func() { h.ChatwootSignIn(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ChatwootSignOut_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("DELETE", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootSignOut(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ChatwootValidateToken_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/auth/test")
|
|
safeCall_Cov15(t, func() { h.ChatwootValidateToken(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ConfirmEmail_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ConfirmEmail(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ConfirmResetPassword_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ConfirmResetPassword(c) })
|
|
}
|
|
|
|
func TestAuthHandler_Login_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"email":"t@t.com","password":"p"}`)
|
|
safeCall_Cov15(t, func() { h.Login(c) })
|
|
}
|
|
|
|
func TestAuthHandler_Logout_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("DELETE", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Logout(c) })
|
|
}
|
|
|
|
func TestAuthHandler_Refresh_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Refresh(c) })
|
|
}
|
|
|
|
func TestAuthHandler_ResetPassword_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/auth/test", map[string]string{"id": "1"}, `{"password":"new"}`)
|
|
safeCall_Cov15(t, func() { h.ResetPassword(c) })
|
|
}
|
|
|
|
func TestAuthHandler_SwitchAccount_Cov15(t *testing.T) {
|
|
h := NewAuthHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/auth/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.SwitchAccount(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_Clone_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Clone(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_List_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_ToggleActive_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleActive(c) })
|
|
}
|
|
|
|
func TestAutomationRuleHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAutomationRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_Create_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_Evaluate_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"message":"m"}`)
|
|
safeCall_Cov15(t, func() { h.Evaluate(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_Get_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_List_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestAutoReplyRuleHandler_Update_Cov15(t *testing.T) {
|
|
h := NewAutoReplyRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestBannerHandler_Create_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestBannerHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestBannerHandler_Get_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestBannerHandler_List_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestBannerHandler_ListActive_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListActive(c) })
|
|
}
|
|
|
|
func TestBannerHandler_Update_Cov15(t *testing.T) {
|
|
h := NewBannerHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_Clone_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Clone(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_Create_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_Get_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_List_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_ListByBot_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListByBot(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_ToggleStatus_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleStatus(c) })
|
|
}
|
|
|
|
func TestBotRuleHandler_Update_Cov15(t *testing.T) {
|
|
h := NewBotRuleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_Create_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_Get_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_List_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_ListByBot_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListByBot(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_ToggleActive_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleActive(c) })
|
|
}
|
|
|
|
func TestBotTriggerConfigHandler_Update_Cov15(t *testing.T) {
|
|
h := NewBotTriggerConfigHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestBulkActionHandler_Create_Cov15(t *testing.T) {
|
|
h := NewBulkActionHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_List_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Start_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Start(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Stop_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Stop(c) })
|
|
}
|
|
|
|
func TestCampaignHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCampaignHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_List_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_Search_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestCannedResponseHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCannedResponseHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_AssociateInbox_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AssociateInbox(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_CreateMessageReport_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"message":"m"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateMessageReport(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_DissociateInbox_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DissociateInbox(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Drilldown_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Drilldown(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_GenerateResponse_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GenerateResponse(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_GetConfig_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetConfig(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_List_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_ListInboxes_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListInboxes(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_SetConfig_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"config":{}}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SetConfig(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Stats_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Stats(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Summary_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Summary(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Tools_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Tools(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_List_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_ProcessResponse_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"response":"r"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ProcessResponse(c) })
|
|
}
|
|
|
|
func TestCaptainAssistantResponseHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainAssistantResponseHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainBulkActionHandler_Execute_Cov15(t *testing.T) {
|
|
h := NewCaptainBulkActionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"ids":[1]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Execute(c) })
|
|
}
|
|
|
|
func TestCaptainConversationHandler_BuildResponse_Cov15(t *testing.T) {
|
|
h := NewCaptainConversationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"message":"m"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.BuildResponse(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_ExecuteTool_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"tool_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ExecuteTool(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_List_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_TestTool_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"tool_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.TestTool(c) })
|
|
}
|
|
|
|
func TestCaptainCustomToolHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainCustomToolHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_List_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_ProcessDocument_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"document_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ProcessDocument(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_SyncDocument_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"document_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SyncDocument(c) })
|
|
}
|
|
|
|
func TestCaptainDocumentHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainDocumentHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainPreferenceHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainPreferenceHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainPreferenceHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainPreferenceHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainPreferenceHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainPreferenceHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainPreferenceHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainPreferenceHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainScenarioHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCaptainScenarioHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCaptainScenarioHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCaptainScenarioHandler_List_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCaptainScenarioHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCaptainScenarioHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCaptainTaskExtendedHandler_FollowUp_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskExtendedHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.FollowUp(c) })
|
|
}
|
|
|
|
func TestCaptainTaskExtendedHandler_LabelSuggestion_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskExtendedHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.LabelSuggestion(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_ReplySuggestion_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReplySuggestion(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_Rewrite_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Rewrite(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_StreamReplySuggestion_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.StreamReplySuggestion(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_StreamRewrite_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.StreamRewrite(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_StreamSummarize_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.StreamSummarize(c) })
|
|
}
|
|
|
|
func TestCaptainTaskHandler_Summarize_Cov15(t *testing.T) {
|
|
h := NewCaptainTaskHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Summarize(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_List_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_PublicGet_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicGet(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_PublicList_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PublicList(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_Reorder_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"ids":[1,2]}`)
|
|
safeCall_Cov15(t, func() { h.Reorder(c) })
|
|
}
|
|
|
|
func TestCategoryHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCategoryHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_AddContact_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddContact(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_CreateNote_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"content":"c"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateNote(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_DeleteNote_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1", "note_id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteNote(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_DestroyCustomAttributes_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DestroyCustomAttributes(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_List_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_ListContacts_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListContacts(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_ListConversations_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListConversations(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_ListNotes_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListNotes(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_RemoveContact_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{"contact_id":1}`)
|
|
safeCall_Cov15(t, func() { h.RemoveContact(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_Search_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_SearchContacts_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.SearchContacts(c) })
|
|
}
|
|
|
|
func TestCompanyHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCompanyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestContactHandler_Active_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Active(c) })
|
|
}
|
|
|
|
func TestContactHandler_ContactableInboxes_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ContactableInboxes(c) })
|
|
}
|
|
|
|
func TestContactHandler_Create_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestContactHandler_CreateContactInbox_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateContactInbox(c) })
|
|
}
|
|
|
|
func TestContactHandler_CreateNote_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"content":"c"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateNote(c) })
|
|
}
|
|
|
|
func TestContactHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestContactHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestContactHandler_DeleteContactInbox_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteContactInbox(c) })
|
|
}
|
|
|
|
func TestContactHandler_DeleteCustomAttributes_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DeleteCustomAttributes(c) })
|
|
}
|
|
|
|
func TestContactHandler_DestroyCustomAttributes_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DestroyCustomAttributes(c) })
|
|
}
|
|
|
|
func TestContactHandler_DestroyNote_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1", "note_id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DestroyNote(c) })
|
|
}
|
|
|
|
func TestContactHandler_DownloadExport_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DownloadExport(c) })
|
|
}
|
|
|
|
func TestContactHandler_Export_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.Export(c) })
|
|
}
|
|
|
|
func TestContactHandler_ExportRequest_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.ExportRequest(c) })
|
|
}
|
|
|
|
func TestContactHandler_Filter_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Filter(c) })
|
|
}
|
|
|
|
func TestContactHandler_Get_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestContactHandler_Import_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"data":{}}`)
|
|
safeCall_Cov15(t, func() { h.Import(c) })
|
|
}
|
|
|
|
func TestContactHandler_InitiateCall_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"phone":"123"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.InitiateCall(c) })
|
|
}
|
|
|
|
func TestContactHandler_List_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestContactHandler_ListAttachments_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListAttachments(c) })
|
|
}
|
|
|
|
func TestContactHandler_ListContactInboxes_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListContactInboxes(c) })
|
|
}
|
|
|
|
func TestContactHandler_ListConversations_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListConversations(c) })
|
|
}
|
|
|
|
func TestContactHandler_ListLabels_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListLabels(c) })
|
|
}
|
|
|
|
func TestContactHandler_ListNotes_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListNotes(c) })
|
|
}
|
|
|
|
func TestContactHandler_Merge_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"child_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Merge(c) })
|
|
}
|
|
|
|
func TestContactHandler_Search_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestContactHandler_ShowNote_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1", "note_id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ShowNote(c) })
|
|
}
|
|
|
|
func TestContactHandler_Update_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestContactHandler_UpdateLabels_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"labels":["a"]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateLabels(c) })
|
|
}
|
|
|
|
func TestContactHandler_UpdateNote_Cov15(t *testing.T) {
|
|
h := NewContactHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1", "note_id": "1"}, `{"content":"c"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateNote(c) })
|
|
}
|
|
|
|
func TestContactInboxHandler_Filter_Cov15(t *testing.T) {
|
|
h := NewContactInboxHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Filter(c) })
|
|
}
|
|
|
|
func TestContactMergeHandler_Create_Cov15(t *testing.T) {
|
|
h := NewContactMergeHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestConversationHandler_AssignAgent_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"agent_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AssignAgent(c) })
|
|
}
|
|
|
|
func TestConversationHandler_AssignTeam_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"team_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AssignTeam(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Create_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Filter_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Filter(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Get_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestConversationHandler_GetLabels_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetLabels(c) })
|
|
}
|
|
|
|
func TestConversationHandler_InboxAssistant_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.InboxAssistant(c) })
|
|
}
|
|
|
|
func TestConversationHandler_List_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestConversationHandler_ListAttachments_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListAttachments(c) })
|
|
}
|
|
|
|
func TestConversationHandler_ListMessages_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListMessages(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Meta_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Meta(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Mute_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Mute(c) })
|
|
}
|
|
|
|
func TestConversationHandler_ReportingEvents_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReportingEvents(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Search_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestConversationHandler_TogglePriority_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.TogglePriority(c) })
|
|
}
|
|
|
|
func TestConversationHandler_ToggleStatus_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleStatus(c) })
|
|
}
|
|
|
|
func TestConversationHandler_ToggleTyping_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleTyping(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Transcript_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Transcript(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Unmute_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Unmute(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Unread_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Unread(c) })
|
|
}
|
|
|
|
func TestConversationHandler_UnreadCounts_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.UnreadCounts(c) })
|
|
}
|
|
|
|
func TestConversationHandler_Update_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestConversationHandler_UpdateCustomAttributes_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"attributes":{}}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateCustomAttributes(c) })
|
|
}
|
|
|
|
func TestConversationHandler_UpdateLabels_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"labels":["a"]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateLabels(c) })
|
|
}
|
|
|
|
func TestConversationHandler_UpdateLastSeen_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"last_seen":0}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateLastSeen(c) })
|
|
}
|
|
|
|
func TestConversationHandler_UpdatePriority_Cov15(t *testing.T) {
|
|
h := NewConversationHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"priority":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdatePriority(c) })
|
|
}
|
|
|
|
func TestConversationInsightHandler_AnalyzeParticipants_Cov15(t *testing.T) {
|
|
h := NewConversationInsightHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AnalyzeParticipants(c) })
|
|
}
|
|
|
|
func TestConversationInsightHandler_ExtractActionItems_Cov15(t *testing.T) {
|
|
h := NewConversationInsightHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ExtractActionItems(c) })
|
|
}
|
|
|
|
func TestConversationInsightHandler_SuggestLabels_Cov15(t *testing.T) {
|
|
h := NewConversationInsightHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SuggestLabels(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_Add_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Add(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_BatchUpdate_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"participants":[]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.BatchUpdate(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_List_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_Remove_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Remove(c) })
|
|
}
|
|
|
|
func TestConversationParticipantHandler_Update_Cov15(t *testing.T) {
|
|
h := NewConversationParticipantHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_AccountGet_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.AccountGet(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_AccountUpdate_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"key":"val"}`)
|
|
safeCall_Cov15(t, func() { h.AccountUpdate(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_PlatformEmbeddingReindexStart_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.PlatformEmbeddingReindexStart(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_PlatformEmbeddingReindexStatus_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.PlatformEmbeddingReindexStatus(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_PlatformGet_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformGet(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_PlatformTest_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.PlatformTest(c) })
|
|
}
|
|
|
|
func TestCopilotConfigHandler_PlatformUpdate_Cov15(t *testing.T) {
|
|
h := NewCopilotConfigHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"key":"val"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PlatformUpdate(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_CreateSuggestionMessage_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"message":"m"}`)
|
|
safeCall_Cov15(t, func() { h.CreateSuggestionMessage(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_CreateThread_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"title":"t"}`)
|
|
safeCall_Cov15(t, func() { h.CreateThread(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_DeleteThread_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteThread(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_GetSuggestedReplies_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetSuggestedReplies(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_GetThread_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetThread(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_ListSuggestionMessages_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListSuggestionMessages(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_ListThreads_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListThreads(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_SendMessage_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"message":"m"}`)
|
|
safeCall_Cov15(t, func() { h.SendMessage(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_SummarizeConversation_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SummarizeConversation(c) })
|
|
}
|
|
|
|
func TestCopilotHandler_TranslateMessage_Cov15(t *testing.T) {
|
|
h := NewCopilotHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"message_id":1}`)
|
|
safeCall_Cov15(t, func() { h.TranslateMessage(c) })
|
|
}
|
|
|
|
func TestCsatMetricsHandler_Download_Cov15(t *testing.T) {
|
|
h := NewCsatMetricsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Download(c) })
|
|
}
|
|
|
|
func TestCsatMetricsHandler_Metrics_Cov15(t *testing.T) {
|
|
h := NewCsatMetricsHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Metrics(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_Download_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Download(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_List_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_Metrics_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Metrics(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_PublicGet_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicGet(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_PublicUpdate_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"rating":5}`)
|
|
safeCall_Cov15(t, func() { h.PublicUpdate(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCsatSurveyHandler_UpdateReviewNotes_Cov15(t *testing.T) {
|
|
h := NewCsatSurveyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"notes":"n"}`)
|
|
safeCall_Cov15(t, func() { h.UpdateReviewNotes(c) })
|
|
}
|
|
|
|
func TestCustomAttributeDefinitionHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCustomAttributeDefinitionHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCustomAttributeDefinitionHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCustomAttributeDefinitionHandler_List_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCustomAttributeDefinitionHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeDefinitionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCustomAttributeValueHandler_RemoveContactAttribute_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeValueHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.RemoveContactAttribute(c) })
|
|
}
|
|
|
|
func TestCustomAttributeValueHandler_RemoveConversationAttribute_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeValueHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.RemoveConversationAttribute(c) })
|
|
}
|
|
|
|
func TestCustomAttributeValueHandler_SetContactAttribute_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeValueHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"value":"v"}`)
|
|
safeCall_Cov15(t, func() { h.SetContactAttribute(c) })
|
|
}
|
|
|
|
func TestCustomAttributeValueHandler_SetConversationAttribute_Cov15(t *testing.T) {
|
|
h := NewCustomAttributeValueHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"value":"v"}`)
|
|
safeCall_Cov15(t, func() { h.SetConversationAttribute(c) })
|
|
}
|
|
|
|
func TestCustomFilterHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCustomFilterHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCustomFilterHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCustomFilterHandler_List_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCustomFilterHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCustomFilterHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestCustomRoleHandler_Create_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestCustomRoleHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestCustomRoleHandler_Get_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestCustomRoleHandler_List_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestCustomRoleHandler_Update_Cov15(t *testing.T) {
|
|
h := NewCustomRoleHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_AddWidget_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"widget_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddWidget(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Create_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Get_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_GetWidgets_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetWidgets(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_List_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Patch_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"name":"n"}`)
|
|
safeCall_Cov15(t, func() { h.Patch(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_RemoveWidget_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"widget_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveWidget(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Search_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_Update_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestDashboardAppHandler_UpdateWidget_Cov15(t *testing.T) {
|
|
h := NewDashboardAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"widget_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateWidget(c) })
|
|
}
|
|
|
|
func TestDeliveryStatusHandler_List_Cov15(t *testing.T) {
|
|
h := NewDeliveryStatusHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Count_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Count(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Create_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_DeleteConversationDraft_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DeleteConversationDraft(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Get_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_List_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Search_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Show_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_Update_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestDraftMessageHandler_UpdateConversationDraft_Cov15(t *testing.T) {
|
|
h := NewDraftMessageHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"content":"c"}`)
|
|
safeCall_Cov15(t, func() { h.UpdateConversationDraft(c) })
|
|
}
|
|
|
|
func TestDyteIntegrationHandler_AddParticipant_Cov15(t *testing.T) {
|
|
h := NewDyteIntegrationHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"user_id":"1"}`)
|
|
safeCall_Cov15(t, func() { h.AddParticipant(c) })
|
|
}
|
|
|
|
func TestDyteIntegrationHandler_CreateMeeting_Cov15(t *testing.T) {
|
|
h := NewDyteIntegrationHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"title":"m"}`)
|
|
safeCall_Cov15(t, func() { h.CreateMeeting(c) })
|
|
}
|
|
|
|
func TestEmailChannelHandler_Create_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestEmailChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestEmailChannelHandler_Get_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestEmailChannelHandler_List_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestEmailChannelHandler_Update_Cov15(t *testing.T) {
|
|
h := NewEmailChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestEmailChannelMigrationHandler_Create_Cov15(t *testing.T) {
|
|
h := NewEmailChannelMigrationHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestEmailChannelMigrationHandler_List_Cov15(t *testing.T) {
|
|
h := NewEmailChannelMigrationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_Checkout_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"plan":"p"}`)
|
|
safeCall_Cov15(t, func() { h.Checkout(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_Limits_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Limits(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_SelectBillingCurrency_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"currency":"usd"}`)
|
|
safeCall_Cov15(t, func() { h.SelectBillingCurrency(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_Subscription_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Subscription(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_ToggleDeletion_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.ToggleDeletion(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_TopupCheckout_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"amount":100}`)
|
|
safeCall_Cov15(t, func() { h.TopupCheckout(c) })
|
|
}
|
|
|
|
func TestEnterpriseAccountHandler_TopupOptions_Cov15(t *testing.T) {
|
|
h := NewEnterpriseAccountHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.TopupOptions(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_CreateFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"page_id":"1"}`)
|
|
safeCall_Cov15(t, func() { h.CreateFacebookPage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_DeleteFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"page_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteFacebookPage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_FacebookPages_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.FacebookPages(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_GetFacebookChannel_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetFacebookChannel(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_GetFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetFacebookPage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_ListFacebookChannels_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListFacebookChannels(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_OAuthCallback_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallback(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_ReauthorizeFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"page_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReauthorizeFacebookPage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_ReauthorizePage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"page_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReauthorizePage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_RegisterFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"page_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterFacebookPage(c) })
|
|
}
|
|
|
|
func TestFacebookChannelHandler_UpdateFacebookPage_Cov15(t *testing.T) {
|
|
h := NewFacebookChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"page_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateFacebookPage(c) })
|
|
}
|
|
|
|
func TestFolderHandler_Create_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestFolderHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestFolderHandler_Get_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestFolderHandler_List_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestFolderHandler_Update_Cov15(t *testing.T) {
|
|
h := NewFolderHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_ChatwootAuthorization_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootAuthorization(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_ListWebhooks_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListWebhooks(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_OAuthCallback_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallback(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_OAuthCallbackGET_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallbackGET(c) })
|
|
}
|
|
|
|
func TestGoogleChannelHandler_RegisterWebhook_Cov15(t *testing.T) {
|
|
h := NewGoogleChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"url":"http://example.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterWebhook(c) })
|
|
}
|
|
|
|
func TestInboxCsatTemplateHandler_Analyze_Cov15(t *testing.T) {
|
|
h := NewInboxCsatTemplateHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Analyze(c) })
|
|
}
|
|
|
|
func TestInboxCsatTemplateHandler_Create_Cov15(t *testing.T) {
|
|
h := NewInboxCsatTemplateHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestInboxCsatTemplateHandler_Show_Cov15(t *testing.T) {
|
|
h := NewInboxCsatTemplateHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestInboxHandler_Create_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestInboxHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestInboxHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestInboxHandler_DisableWhatsAppCalling_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DisableWhatsAppCalling(c) })
|
|
}
|
|
|
|
func TestInboxHandler_EnableWhatsAppCalling_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.EnableWhatsAppCalling(c) })
|
|
}
|
|
|
|
func TestInboxHandler_Get_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestInboxHandler_GetAgentBot_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetAgentBot(c) })
|
|
}
|
|
|
|
func TestInboxHandler_Health_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Health(c) })
|
|
}
|
|
|
|
func TestInboxHandler_List_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestInboxHandler_ListCampaigns_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListCampaigns(c) })
|
|
}
|
|
|
|
func TestInboxHandler_RegisterWebhook_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"url":"http://example.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterWebhook(c) })
|
|
}
|
|
|
|
func TestInboxHandler_ResetSecret_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ResetSecret(c) })
|
|
}
|
|
|
|
func TestInboxHandler_SetAgentBot_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"agent_bot_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SetAgentBot(c) })
|
|
}
|
|
|
|
func TestInboxHandler_SetInboundCalls_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"enabled":true}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SetInboundCalls(c) })
|
|
}
|
|
|
|
func TestInboxHandler_SyncTemplates_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SyncTemplates(c) })
|
|
}
|
|
|
|
func TestInboxHandler_Update_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestInboxHandler_WhatsAppAuthorization_Cov15(t *testing.T) {
|
|
h := NewInboxHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.WhatsAppAuthorization(c) })
|
|
}
|
|
|
|
func TestInboxLimitHandler_Create_Cov15(t *testing.T) {
|
|
h := NewInboxLimitHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestInboxLimitHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewInboxLimitHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestInboxLimitHandler_Update_Cov15(t *testing.T) {
|
|
h := NewInboxLimitHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_AddMember_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddMember(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_CreateAccountScoped_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1,"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateAccountScoped(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_DestroyAccountScoped_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DestroyAccountScoped(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_ListMembers_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListMembers(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_RemoveMember_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveMember(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_ShowAccountScoped_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ShowAccountScoped(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_UpdateAccountScoped_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1,"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateAccountScoped(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_UpdateMember_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"user_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateMember(c) })
|
|
}
|
|
|
|
func TestInboxMemberHandler_UpdateMultiple_Cov15(t *testing.T) {
|
|
h := NewInboxMemberHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"members":[]}`)
|
|
safeCall_Cov15(t, func() { h.UpdateMultiple(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_ChatwootAuthorization_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootAuthorization(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_CreateInstagramChannel_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"instagram_id":"1"}`)
|
|
safeCall_Cov15(t, func() { h.CreateInstagramChannel(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_DeleteComment_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"comment_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteComment(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_DeleteInstagramChannel_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteInstagramChannel(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_GetCommentReplies_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetCommentReplies(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_GetComments_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetComments(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_GetInstagramChannel_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetInstagramChannel(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_HideComment_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"comment_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.HideComment(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_ListInstagramChannels_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListInstagramChannels(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_ListWebhooks_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListWebhooks(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_OAuthCallback_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallback(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_OAuthCallbackGET_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallbackGET(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_Reauthorize_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.Reauthorize(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_RegisterWebhook_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"url":"http://example.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterWebhook(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_ReplyToComment_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"comment_id":"1","message":"m"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReplyToComment(c) })
|
|
}
|
|
|
|
func TestInstagramChannelHandler_UpdateInstagramChannel_Cov15(t *testing.T) {
|
|
h := NewInstagramChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"instagram_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateInstagramChannel(c) })
|
|
}
|
|
|
|
func TestInstallationConfigHandler_Create_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestInstallationConfigHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestInstallationConfigHandler_Get_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestInstallationConfigHandler_List_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestInstallationConfigHandler_Update_Cov15(t *testing.T) {
|
|
h := NewInstallationConfigHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_CreateHook_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"hook":{"event":"test"}}`)
|
|
safeCall_Cov15(t, func() { h.CreateHook(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_DeleteHook_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteHook(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_GetApp_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetApp(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_GetHook_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetHook(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_ListApps_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListApps(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_ListHooks_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListHooks(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_ProcessHookEvent_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"event":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ProcessHookEvent(c) })
|
|
}
|
|
|
|
func TestIntegrationHookHandler_UpdateHook_Cov15(t *testing.T) {
|
|
h := NewIntegrationHookHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"hook":{"event":"test"}}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateHook(c) })
|
|
}
|
|
|
|
func TestLabelHandler_AddLabelToConversation_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"labels":["a"]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddLabelToConversation(c) })
|
|
}
|
|
|
|
func TestLabelHandler_BatchAddLabel_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"labels":["a"]}`)
|
|
safeCall_Cov15(t, func() { h.BatchAddLabel(c) })
|
|
}
|
|
|
|
func TestLabelHandler_BatchRemoveLabel_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"labels":["a"]}`)
|
|
safeCall_Cov15(t, func() { h.BatchRemoveLabel(c) })
|
|
}
|
|
|
|
func TestLabelHandler_CreateTag_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"tag"}`)
|
|
safeCall_Cov15(t, func() { h.CreateTag(c) })
|
|
}
|
|
|
|
func TestLabelHandler_DeleteTag_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteTag(c) })
|
|
}
|
|
|
|
func TestLabelHandler_GetConversationLabels_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetConversationLabels(c) })
|
|
}
|
|
|
|
func TestLabelHandler_GetConversationsByTag_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetConversationsByTag(c) })
|
|
}
|
|
|
|
func TestLabelHandler_GetTag_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetTag(c) })
|
|
}
|
|
|
|
func TestLabelHandler_ListTags_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListTags(c) })
|
|
}
|
|
|
|
func TestLabelHandler_RemoveLabelFromConversation_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"labels":["a"]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveLabelFromConversation(c) })
|
|
}
|
|
|
|
func TestLabelHandler_ReplaceConversationLabels_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"labels":["a"]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ReplaceConversationLabels(c) })
|
|
}
|
|
|
|
func TestLabelHandler_UpdateTag_Cov15(t *testing.T) {
|
|
h := NewLabelHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"tag"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateTag(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_CreateIssue_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"title":"t"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.CreateIssue(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_GetLinkedIssues_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetLinkedIssues(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_GetTeamEntities_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetTeamEntities(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_GetTeams_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetTeams(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_LinkIssue_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"issue_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.LinkIssue(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_SearchIssue_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SearchIssue(c) })
|
|
}
|
|
|
|
func TestLinearIntegrationHandler_UnlinkIssue_Cov15(t *testing.T) {
|
|
h := NewLinearIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"issue_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UnlinkIssue(c) })
|
|
}
|
|
|
|
func TestLINEChannelHandler_Create_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestLINEChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestLINEChannelHandler_Get_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestLINEChannelHandler_List_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestLINEChannelHandler_Update_Cov15(t *testing.T) {
|
|
h := NewLINEChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestLiveReportHandler_ConversationMetrics_Cov15(t *testing.T) {
|
|
h := NewLiveReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ConversationMetrics(c) })
|
|
}
|
|
|
|
func TestLiveReportHandler_GroupedConversationMetrics_Cov15(t *testing.T) {
|
|
h := NewLiveReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GroupedConversationMetrics(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Clone_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Clone(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Create_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Execute_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"ids":[1]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Execute(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Get_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestMacroHandler_List_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestMacroHandler_ToggleActive_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ToggleActive(c) })
|
|
}
|
|
|
|
func TestMacroHandler_Update_Cov15(t *testing.T) {
|
|
h := NewMacroHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Create_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Get_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestMessageHandler_List_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Retry_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Retry(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Search_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Translate_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Translate(c) })
|
|
}
|
|
|
|
func TestMessageHandler_Update_Cov15(t *testing.T) {
|
|
h := NewMessageHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_ChatwootAuthorization_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootAuthorization(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_ListWebhooks_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListWebhooks(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_OAuthCallback_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallback(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_OAuthCallbackGET_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallbackGET(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_RegisterWebhook_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"url":"http://example.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterWebhook(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_WebhookEvent_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.WebhookEvent(c) })
|
|
}
|
|
|
|
func TestMicrosoftChannelHandler_WebhookValidation_Cov15(t *testing.T) {
|
|
h := NewMicrosoftChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.WebhookValidation(c) })
|
|
}
|
|
|
|
func TestNoteHandler_Create_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestNoteHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestNoteHandler_List_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestNoteHandler_Show_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestNoteHandler_Update_Cov15(t *testing.T) {
|
|
h := NewNoteHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_DestroyAll_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.DestroyAll(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_Get_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_List_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_MarkAllRead_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.MarkAllRead(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_Snooze_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Snooze(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_Unread_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Unread(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_UnreadCount_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.UnreadCount(c) })
|
|
}
|
|
|
|
func TestNotificationHandler_Update_Cov15(t *testing.T) {
|
|
h := NewNotificationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestNotificationSettingHandler_Show_Cov15(t *testing.T) {
|
|
h := NewNotificationSettingHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestNotificationSettingHandler_Update_Cov15(t *testing.T) {
|
|
h := NewNotificationSettingHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestNotificationSubscriptionHandler_Create_Cov15(t *testing.T) {
|
|
h := NewNotificationSubscriptionHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestNotificationSubscriptionHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewNotificationSubscriptionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestNotionIntegrationHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewNotionIntegrationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestNotionIntegrationHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewNotionIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestOIDCHandler_Authorize_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{}`)
|
|
safeCall_Cov15(t, func() { h.Authorize(c) })
|
|
}
|
|
|
|
func TestOIDCHandler_Callback_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{}`)
|
|
safeCall_Cov15(t, func() { h.Callback(c) })
|
|
}
|
|
|
|
func TestOIDCHandler_Discovery_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.Discovery(c) })
|
|
}
|
|
|
|
func TestOIDCHandler_GetConfig_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.GetConfig(c) })
|
|
}
|
|
|
|
func TestOIDCHandler_UpdateConfig_Cov15(t *testing.T) {
|
|
h := NewOIDCHandler(nil, nil, nil, nil, nil)
|
|
c, _ := newCtxBody_Cov15("PUT", "/platform/test", `{"config":{}}`)
|
|
safeCall_Cov15(t, func() { h.UpdateConfig(c) })
|
|
}
|
|
|
|
func TestPlatformAccountHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPlatformAccountHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestPlatformAccountHandler_List_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPlatformAccountHandler_Show_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestPlatformAccountHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestPlatformAccountUserHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountUserHandler(nil, nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPlatformAccountUserHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountUserHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestPlatformAccountUserHandler_Index_Cov15(t *testing.T) {
|
|
h := NewPlatformAccountUserHandler(nil, nil, nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.Index(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_List_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_Show_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestPlatformAgentBotHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPlatformAgentBotHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_AddPermissible_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/platform/test", map[string]string{"id": "1"}, `{"id":1}`)
|
|
safeCall_Cov15(t, func() { h.AddPermissible(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_Get_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_List_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_ListAccessTokens_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.ListAccessTokens(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_ListPermissibles_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.ListPermissibles(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_RegenerateAccessToken_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.RegenerateAccessToken(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_RemovePermissible_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{"id":1}`)
|
|
safeCall_Cov15(t, func() { h.RemovePermissible(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_Search_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.Search(c) })
|
|
}
|
|
|
|
func TestPlatformAppHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPlatformAppHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Destroy_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/platform/test", map[string]string{"id": "1"}, `{}`)
|
|
safeCall_Cov15(t, func() { h.Destroy(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_List_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Login_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"email":"t@t.com","password":"p"}`)
|
|
safeCall_Cov15(t, func() { h.Login(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Show_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/platform/test", map[string]string{"id": "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Token_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"email":"t@t.com","password":"p"}`)
|
|
safeCall_Cov15(t, func() { h.Token(c) })
|
|
}
|
|
|
|
func TestPlatformUserHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPlatformUserHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/platform/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestPlatformUserSSOHandler_GetSSOLink_Cov15(t *testing.T) {
|
|
h := NewPlatformUserSSOHandler()
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.GetSSOLink(c) })
|
|
}
|
|
|
|
func TestPlatformUserSSOHandler_GetSSOToken_Cov15(t *testing.T) {
|
|
h := NewPlatformUserSSOHandler()
|
|
c, _ := newCtx_Cov15("GET", "/platform/test")
|
|
safeCall_Cov15(t, func() { h.GetSSOToken(c) })
|
|
}
|
|
|
|
func TestPortalHandler_Archive_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Archive(c) })
|
|
}
|
|
|
|
func TestPortalHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPortalHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestPortalHandler_Get_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestPortalHandler_List_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPortalHandler_PublicGet_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicGet(c) })
|
|
}
|
|
|
|
func TestPortalHandler_PublicRedirectDefaultLocale_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicRedirectDefaultLocale(c) })
|
|
}
|
|
|
|
func TestPortalHandler_PublicSitemap_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.PublicSitemap(c) })
|
|
}
|
|
|
|
func TestPortalHandler_RemoveLogo_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveLogo(c) })
|
|
}
|
|
|
|
func TestPortalHandler_SendInstructions_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"email":"t@t.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SendInstructions(c) })
|
|
}
|
|
|
|
func TestPortalHandler_SSLStatus_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.SSLStatus(c) })
|
|
}
|
|
|
|
func TestPortalHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPortalHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestPortalMemberHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPortalMemberHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestPortalMemberHandler_Get_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestPortalMemberHandler_List_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestPortalMemberHandler_Update_Cov15(t *testing.T) {
|
|
h := NewPortalMemberHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestProfileHandler_DeleteAvatar_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteAvatar(c) })
|
|
}
|
|
|
|
func TestProfileHandler_Get_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestProfileHandler_ListSessions_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListSessions(c) })
|
|
}
|
|
|
|
func TestProfileHandler_ResendConfirmation_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.ResendConfirmation(c) })
|
|
}
|
|
|
|
func TestProfileHandler_ResetAccessToken_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.ResetAccessToken(c) })
|
|
}
|
|
|
|
func TestProfileHandler_RevokeSession_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{"id":"1"}`)
|
|
safeCall_Cov15(t, func() { h.RevokeSession(c) })
|
|
}
|
|
|
|
func TestProfileHandler_SetActiveAccount_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"account_id":1}`)
|
|
safeCall_Cov15(t, func() { h.SetActiveAccount(c) })
|
|
}
|
|
|
|
func TestProfileHandler_SetAutoOffline_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"auto_offline":true}`)
|
|
safeCall_Cov15(t, func() { h.SetAutoOffline(c) })
|
|
}
|
|
|
|
func TestProfileHandler_SetAvailability_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"availability":"online"}`)
|
|
safeCall_Cov15(t, func() { h.SetAvailability(c) })
|
|
}
|
|
|
|
func TestProfileHandler_Update_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestProfileHandler_UpdateAvatar_Cov15(t *testing.T) {
|
|
h := NewProfileHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateAvatar(c) })
|
|
}
|
|
|
|
func TestPushSubscriptionHandler_Create_Cov15(t *testing.T) {
|
|
h := NewPushSubscriptionHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestPushSubscriptionHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewPushSubscriptionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestPushSubscriptionHandler_List_Cov15(t *testing.T) {
|
|
h := NewPushSubscriptionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestRAGHandler_IndexResponse_Cov15(t *testing.T) {
|
|
h := NewRAGHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.IndexResponse(c) })
|
|
}
|
|
|
|
func TestRAGHandler_Query_Cov15(t *testing.T) {
|
|
h := NewRAGHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.Query(c) })
|
|
}
|
|
|
|
func TestReportingEventHandler_List_Cov15(t *testing.T) {
|
|
h := NewReportingEventHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestSearchHandler_GlobalSearch_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GlobalSearch(c) })
|
|
}
|
|
|
|
func TestSearchHandler_SearchArticles_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SearchArticles(c) })
|
|
}
|
|
|
|
func TestSearchHandler_SearchContacts_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"query":"q"}`)
|
|
safeCall_Cov15(t, func() { h.SearchContacts(c) })
|
|
}
|
|
|
|
func TestSearchHandler_SearchConversations_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SearchConversations(c) })
|
|
}
|
|
|
|
func TestSearchHandler_SearchMessages_Cov15(t *testing.T) {
|
|
h := NewSearchHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.SearchMessages(c) })
|
|
}
|
|
|
|
func TestShopifyIntegrationHandler_Auth_Cov15(t *testing.T) {
|
|
h := NewShopifyIntegrationHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"code":"c"}`)
|
|
safeCall_Cov15(t, func() { h.Auth(c) })
|
|
}
|
|
|
|
func TestShopifyIntegrationHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewShopifyIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestShopifyIntegrationHandler_GetOrders_Cov15(t *testing.T) {
|
|
h := NewShopifyIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetOrders(c) })
|
|
}
|
|
|
|
func TestSlackIntegrationHandler_Create_Cov15(t *testing.T) {
|
|
h := NewSlackIntegrationHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestSlackIntegrationHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewSlackIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestSlackIntegrationHandler_ListAllChannels_Cov15(t *testing.T) {
|
|
h := NewSlackIntegrationHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListAllChannels(c) })
|
|
}
|
|
|
|
func TestSlackIntegrationHandler_Update_Cov15(t *testing.T) {
|
|
h := NewSlackIntegrationHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_AddInbox_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"inbox_id":1}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddInbox(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_Create_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_Get_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_GetAppliedSlaDownload_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetAppliedSlaDownload(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_GetAppliedSlaMetrics_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetAppliedSlaMetrics(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_List_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_ListAppliedSlas_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListAppliedSlas(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_ListInboxes_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListInboxes(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_RemoveInbox_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"inbox_id": "1", "id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveInbox(c) })
|
|
}
|
|
|
|
func TestSlaPolicyHandler_Update_Cov15(t *testing.T) {
|
|
h := NewSlaPolicyHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestSSEEventHandler_StreamEvents_Cov15(t *testing.T) {
|
|
h := NewSSEEventHandler(nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.StreamEvents(c) })
|
|
}
|
|
|
|
func TestSSEStreamHandler_StreamCopilotMessage_Cov15(t *testing.T) {
|
|
h := NewSSEStreamHandler(nil, nil)
|
|
c, _ := newCtxBody_Cov15("POST", "/platform/test", `{"message":"m"}`)
|
|
safeCall_Cov15(t, func() { h.StreamCopilotMessage(c) })
|
|
}
|
|
|
|
func TestSSOSessionHandler_CountByUser_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.CountByUser(c) })
|
|
}
|
|
|
|
func TestSSOSessionHandler_Get_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestSSOSessionHandler_ListByUser_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListByUser(c) })
|
|
}
|
|
|
|
func TestSSOSessionHandler_Terminate_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Terminate(c) })
|
|
}
|
|
|
|
func TestSSOSessionHandler_TerminateAllByUser_Cov15(t *testing.T) {
|
|
h := NewSSOSessionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.TerminateAllByUser(c) })
|
|
}
|
|
|
|
func TestSummaryReportHandler_Agent_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Agent(c) })
|
|
}
|
|
|
|
func TestSummaryReportHandler_Channel_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Channel(c) })
|
|
}
|
|
|
|
func TestSummaryReportHandler_Inbox_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Inbox(c) })
|
|
}
|
|
|
|
func TestSummaryReportHandler_Label_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Label(c) })
|
|
}
|
|
|
|
func TestSummaryReportHandler_Team_Cov15(t *testing.T) {
|
|
h := NewSummaryReportHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Team(c) })
|
|
}
|
|
|
|
func TestTeamHandler_AddMembers_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"member_ids":[1]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.AddMembers(c) })
|
|
}
|
|
|
|
func TestTeamHandler_Create_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestTeamHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestTeamHandler_Get_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestTeamHandler_List_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestTeamHandler_ListMembers_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListMembers(c) })
|
|
}
|
|
|
|
func TestTeamHandler_RemoveMembers_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"member_ids":[1]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RemoveMembers(c) })
|
|
}
|
|
|
|
func TestTeamHandler_Update_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestTeamHandler_UpdateMembers_Cov15(t *testing.T) {
|
|
h := NewTeamHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"member_ids":[1]}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateMembers(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_ChatwootAuthorization_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootAuthorization(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_CreateTikTokChannel_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"tiktok_id":"1"}`)
|
|
safeCall_Cov15(t, func() { h.CreateTikTokChannel(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_DeleteTikTokChannel_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteTikTokChannel(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_GetTikTokChannel_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetTikTokChannel(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_ListTikTokChannels_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListTikTokChannels(c) })
|
|
}
|
|
|
|
func TestTikTokChannelHandler_UpdateTikTokChannel_Cov15(t *testing.T) {
|
|
h := NewTikTokChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"tiktok_id":"1"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateTikTokChannel(c) })
|
|
}
|
|
|
|
func TestTwilioChannelHandler_Create_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestTwilioChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestTwilioChannelHandler_Get_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestTwilioChannelHandler_List_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestTwilioChannelHandler_Update_Cov15(t *testing.T) {
|
|
h := NewTwilioChannelHandler(nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_Authorization_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Authorization(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_ChatwootAuthorization_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ChatwootAuthorization(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_ListWebhooks_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListWebhooks(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_OAuthCallback_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallback(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_OAuthCallbackGET_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.OAuthCallbackGET(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_RegisterWebhook_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"url":"http://example.com"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.RegisterWebhook(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_WebhookCRC_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.WebhookCRC(c) })
|
|
}
|
|
|
|
func TestTwitterChannelHandler_WebhookEvent_Cov15(t *testing.T) {
|
|
h := NewTwitterChannelHandler(nil, nil, nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.WebhookEvent(c) })
|
|
}
|
|
|
|
func TestUploadHandler_AccountDirectUpload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.AccountDirectUpload(c) })
|
|
}
|
|
|
|
func TestUploadHandler_CompleteConversationDirectUpload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.CompleteConversationDirectUpload(c) })
|
|
}
|
|
|
|
func TestUploadHandler_CompleteWidgetDirectUpload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.CompleteWidgetDirectUpload(c) })
|
|
}
|
|
|
|
func TestUploadHandler_ConversationDirectUpload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.ConversationDirectUpload(c) })
|
|
}
|
|
|
|
func TestUploadHandler_DirectUpload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.DirectUpload(c) })
|
|
}
|
|
|
|
func TestUploadHandler_Upload_Cov15(t *testing.T) {
|
|
h := NewUploadHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Upload(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_Create_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_Get_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_List_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_ListDeliveries_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListDeliveries(c) })
|
|
}
|
|
|
|
func TestWebhookSubscriptionHandler_Update_Cov15(t *testing.T) {
|
|
h := NewWebhookSubscriptionHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestWebWidgetHandler_CreateWebWidgetInbox_Cov15(t *testing.T) {
|
|
h := NewWebWidgetHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"w"}`)
|
|
safeCall_Cov15(t, func() { h.CreateWebWidgetInbox(c) })
|
|
}
|
|
|
|
func TestWebWidgetHandler_DeleteWebWidgetInbox_Cov15(t *testing.T) {
|
|
h := NewWebWidgetHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteWebWidgetInbox(c) })
|
|
}
|
|
|
|
func TestWebWidgetHandler_GetWebWidgetConfig_Cov15(t *testing.T) {
|
|
h := NewWebWidgetHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetWebWidgetConfig(c) })
|
|
}
|
|
|
|
func TestWebWidgetHandler_UpdateWebWidgetConfig_Cov15(t *testing.T) {
|
|
h := NewWebWidgetHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"w"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateWebWidgetConfig(c) })
|
|
}
|
|
|
|
func TestWebWidgetOfflineHandler_ConvertOfflineMessage_Cov15(t *testing.T) {
|
|
h := NewWebWidgetOfflineHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"message":"m"}`)
|
|
safeCall_Cov15(t, func() { h.ConvertOfflineMessage(c) })
|
|
}
|
|
|
|
func TestWebWidgetOfflineHandler_DismissOfflineMessage_Cov15(t *testing.T) {
|
|
h := NewWebWidgetOfflineHandler(nil, nil)
|
|
c, _ := ctxWithAcctBody_Cov15("DELETE", "/api/v1/accounts/1/test", "1", `{}`)
|
|
safeCall_Cov15(t, func() { h.DismissOfflineMessage(c) })
|
|
}
|
|
|
|
func TestWebWidgetOfflineHandler_ListOfflineMessages_Cov15(t *testing.T) {
|
|
h := NewWebWidgetOfflineHandler(nil, nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListOfflineMessages(c) })
|
|
}
|
|
|
|
func TestWebWidgetOfflineHandler_ListOfflineMessagesByInbox_Cov15(t *testing.T) {
|
|
h := NewWebWidgetOfflineHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.ListOfflineMessagesByInbox(c) })
|
|
}
|
|
|
|
func TestWebWidgetPreChatHandler_DeletePreChatForm_Cov15(t *testing.T) {
|
|
h := NewWebWidgetPreChatHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeletePreChatForm(c) })
|
|
}
|
|
|
|
func TestWebWidgetPreChatHandler_GetPreChatForm_Cov15(t *testing.T) {
|
|
h := NewWebWidgetPreChatHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetPreChatForm(c) })
|
|
}
|
|
|
|
func TestWebWidgetPreChatHandler_UpdatePreChatForm_Cov15(t *testing.T) {
|
|
h := NewWebWidgetPreChatHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"form":{}}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdatePreChatForm(c) })
|
|
}
|
|
|
|
func TestWebWidgetThemeHandler_DeleteThemeConfig_Cov15(t *testing.T) {
|
|
h := NewWebWidgetThemeHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.DeleteThemeConfig(c) })
|
|
}
|
|
|
|
func TestWebWidgetThemeHandler_GetThemeConfig_Cov15(t *testing.T) {
|
|
h := NewWebWidgetThemeHandler(nil, nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.GetThemeConfig(c) })
|
|
}
|
|
|
|
func TestWebWidgetThemeHandler_UpdateThemeConfig_Cov15(t *testing.T) {
|
|
h := NewWebWidgetThemeHandler(nil, nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"theme":{}}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UpdateThemeConfig(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Accept_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Accept(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Create_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("POST", "/api/v1/accounts/1/test", "1", `{"name":"test"}`)
|
|
safeCall_Cov15(t, func() { h.Create(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Delete_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Delete(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Get_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Get(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Index_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Index(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Initiate_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Initiate(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_List_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.List(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Reject_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Reject(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Show_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Terminate_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("DELETE", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Terminate(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_Update_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("PUT", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{"name":"test"}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Update(c) })
|
|
}
|
|
|
|
func TestWhatsAppCallHandler_UploadRecording_Cov15(t *testing.T) {
|
|
h := NewWhatsAppCallHandler(nil)
|
|
c, _ := newCtxParamsBody_Cov15("POST", "/api/v1/accounts/1/test", map[string]string{"id": "1"}, `{}`)
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.UploadRecording(c) })
|
|
}
|
|
|
|
func TestWidgetTestHandler_Index_Cov15(t *testing.T) {
|
|
h := NewWidgetTestHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.Index(c) })
|
|
}
|
|
|
|
func TestWidgetTestHandler_ListByType_Cov15(t *testing.T) {
|
|
h := NewWidgetTestHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.ListByType(c) })
|
|
}
|
|
|
|
func TestWorkingHourHandler_GetWeeklySchedule_Cov15(t *testing.T) {
|
|
h := NewWorkingHourHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.GetWeeklySchedule(c) })
|
|
}
|
|
|
|
func TestWorkingHourHandler_IsOutOfOffice_Cov15(t *testing.T) {
|
|
h := NewWorkingHourHandler(nil)
|
|
c, _ := ctxWithAcct_Cov15("GET", "/api/v1/accounts/1/test", "1")
|
|
safeCall_Cov15(t, func() { h.IsOutOfOffice(c) })
|
|
}
|
|
|
|
func TestWorkingHourHandler_UpdateWeeklySchedule_Cov15(t *testing.T) {
|
|
h := NewWorkingHourHandler(nil)
|
|
c, _ := ctxWithAcctBody_Cov15("PUT", "/api/v1/accounts/1/test", "1", `{"schedule":{}}`)
|
|
safeCall_Cov15(t, func() { h.UpdateWeeklySchedule(c) })
|
|
}
|
|
|
|
func TestYearInReviewHandler_Show_Cov15(t *testing.T) {
|
|
h := NewYearInReviewHandler(nil)
|
|
c, _ := newCtxParams_Cov15("GET", "/api/v1/accounts/1/test", map[string]string{"id": "1"})
|
|
c.Params = append(c.Params, gin.Param{Key: "account_id", Value: "1"})
|
|
safeCall_Cov15(t, func() { h.Show(c) })
|
|
}
|