// Code generated by mockery v2.46.0. DO NOT EDIT.

package mocks

import (
	context "context"

	fs "io/fs"

	host "github.com/taubyte/tau/pkg/mycelium/host"

	io "io"

	mock "github.com/stretchr/testify/mock"
)

// RemoteHost is an autogenerated mock type for the RemoteHost type
type RemoteHost struct {
	mock.Mock
}

// Execute provides a mock function with given fields: ctx, name, args
func (_m *RemoteHost) Execute(ctx context.Context, name string, args ...string) ([]byte, error) {
	_va := make([]interface{}, len(args))
	for _i := range args {
		_va[_i] = args[_i]
	}
	var _ca []interface{}
	_ca = append(_ca, ctx, name)
	_ca = append(_ca, _va...)
	ret := _m.Called(_ca...)

	if len(ret) == 0 {
		panic("no return value specified for Execute")
	}

	var r0 []byte
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, string, ...string) ([]byte, error)); ok {
		return rf(ctx, name, args...)
	}
	if rf, ok := ret.Get(0).(func(context.Context, string, ...string) []byte); ok {
		r0 = rf(ctx, name, args...)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]byte)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, string, ...string) error); ok {
		r1 = rf(ctx, name, args...)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Host provides a mock function with given fields:
func (_m *RemoteHost) Host() host.Host {
	ret := _m.Called()

	if len(ret) == 0 {
		panic("no return value specified for Host")
	}

	var r0 host.Host
	if rf, ok := ret.Get(0).(func() host.Host); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(host.Host)
		}
	}

	return r0
}

// Open provides a mock function with given fields: path
func (_m *RemoteHost) Open(path string) (io.ReadCloser, error) {
	ret := _m.Called(path)

	if len(ret) == 0 {
		panic("no return value specified for Open")
	}

	var r0 io.ReadCloser
	var r1 error
	if rf, ok := ret.Get(0).(func(string) (io.ReadCloser, error)); ok {
		return rf(path)
	}
	if rf, ok := ret.Get(0).(func(string) io.ReadCloser); ok {
		r0 = rf(path)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(io.ReadCloser)
		}
	}

	if rf, ok := ret.Get(1).(func(string) error); ok {
		r1 = rf(path)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// OpenFile provides a mock function with given fields: path, flag, perm
func (_m *RemoteHost) OpenFile(path string, flag int, perm fs.FileMode) (io.ReadWriteCloser, error) {
	ret := _m.Called(path, flag, perm)

	if len(ret) == 0 {
		panic("no return value specified for OpenFile")
	}

	var r0 io.ReadWriteCloser
	var r1 error
	if rf, ok := ret.Get(0).(func(string, int, fs.FileMode) (io.ReadWriteCloser, error)); ok {
		return rf(path, flag, perm)
	}
	if rf, ok := ret.Get(0).(func(string, int, fs.FileMode) io.ReadWriteCloser); ok {
		r0 = rf(path, flag, perm)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(io.ReadWriteCloser)
		}
	}

	if rf, ok := ret.Get(1).(func(string, int, fs.FileMode) error); ok {
		r1 = rf(path, flag, perm)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// Remove provides a mock function with given fields: name
func (_m *RemoteHost) Remove(name string) error {
	ret := _m.Called(name)

	if len(ret) == 0 {
		panic("no return value specified for Remove")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(string) error); ok {
		r0 = rf(name)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// RemoveAll provides a mock function with given fields: path
func (_m *RemoteHost) RemoveAll(path string) error {
	ret := _m.Called(path)

	if len(ret) == 0 {
		panic("no return value specified for RemoveAll")
	}

	var r0 error
	if rf, ok := ret.Get(0).(func(string) error); ok {
		r0 = rf(path)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

// Sudo provides a mock function with given fields: ctx, name, args
func (_m *RemoteHost) Sudo(ctx context.Context, name string, args ...string) ([]byte, error) {
	_va := make([]interface{}, len(args))
	for _i := range args {
		_va[_i] = args[_i]
	}
	var _ca []interface{}
	_ca = append(_ca, ctx, name)
	_ca = append(_ca, _va...)
	ret := _m.Called(_ca...)

	if len(ret) == 0 {
		panic("no return value specified for Sudo")
	}

	var r0 []byte
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, string, ...string) ([]byte, error)); ok {
		return rf(ctx, name, args...)
	}
	if rf, ok := ret.Get(0).(func(context.Context, string, ...string) []byte); ok {
		r0 = rf(ctx, name, args...)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]byte)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, string, ...string) error); ok {
		r1 = rf(ctx, name, args...)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

// newRemoteHost creates a new instance of RemoteHost. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRemoteHost(t interface {
	mock.TestingT
	Cleanup(func())
}) *RemoteHost {
	mock := &RemoteHost{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
