mirror of
https://gitlab.bertha.cloud/partitio/Nextcloud-Partitio/gonextcloud
synced 2024-11-13 06:46:25 +00:00
Added missing login and logout method to client interface, updated mocks
This commit is contained in:
parent
dd062fe989
commit
2953afd160
@ -9,6 +9,8 @@ type Client interface {
|
||||
Shares() Shares
|
||||
Users() Users
|
||||
Groups() Groups
|
||||
Login(username string, password string) error
|
||||
Logout() error
|
||||
}
|
||||
|
||||
type Auth interface {
|
||||
|
@ -1,44 +1,151 @@
|
||||
// Code generated by mockery v1.0.0. DO NOT EDIT.
|
||||
|
||||
package mocks
|
||||
|
||||
import (
|
||||
"gitlab.bertha.cloud/partitio/Nextcloud-Partitio/gonextcloud/types"
|
||||
)
|
||||
import mock "github.com/stretchr/testify/mock"
|
||||
import types "gitlab.bertha.cloud/partitio/Nextcloud-Partitio/gonextcloud/types"
|
||||
|
||||
// Client is an autogenerated mock type for the Client type
|
||||
type Client struct {
|
||||
mock.Mock
|
||||
}
|
||||
|
||||
// Apps provides a mock function with given fields:
|
||||
func (_m *Client) Apps() types.Apps {
|
||||
return new(Apps)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.Apps
|
||||
if rf, ok := ret.Get(0).(func() types.Apps); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.Apps)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// AppsConfig provides a mock function with given fields:
|
||||
func (_m *Client) AppsConfig() types.AppsConfig {
|
||||
return new(AppsConfig)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.AppsConfig
|
||||
if rf, ok := ret.Get(0).(func() types.AppsConfig); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.AppsConfig)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// GroupFolders provides a mock function with given fields:
|
||||
func (_m *Client) GroupFolders() types.GroupFolders {
|
||||
return new(GroupFolders)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.GroupFolders
|
||||
if rf, ok := ret.Get(0).(func() types.GroupFolders); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.GroupFolders)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Groups provides a mock function with given fields:
|
||||
func (_m *Client) Groups() types.Groups {
|
||||
return new(Groups)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.Groups
|
||||
if rf, ok := ret.Get(0).(func() types.Groups); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.Groups)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Login provides a mock function with given fields: username, password
|
||||
func (_m *Client) Login(username string, password string) error {
|
||||
ret := _m.Called(username, password)
|
||||
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string, string) error); ok {
|
||||
r0 = rf(username, password)
|
||||
} else {
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Logout provides a mock function with given fields:
|
||||
func (_m *Client) Logout() error {
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func() error); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Notifications provides a mock function with given fields:
|
||||
func (_m *Client) Notifications() types.Notifications {
|
||||
return new(Notifications)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.Notifications
|
||||
if rf, ok := ret.Get(0).(func() types.Notifications); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.Notifications)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Shares provides a mock function with given fields:
|
||||
func (_m *Client) Shares() types.Shares {
|
||||
return new(Shares)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.Shares
|
||||
if rf, ok := ret.Get(0).(func() types.Shares); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.Shares)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// Users provides a mock function with given fields:
|
||||
func (_m *Client) Users() types.Users {
|
||||
return new(Users)
|
||||
ret := _m.Called()
|
||||
|
||||
var r0 types.Users
|
||||
if rf, ok := ret.Get(0).(func() types.Users); ok {
|
||||
r0 = rf()
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(types.Users)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user