-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfake.go
More file actions
169 lines (127 loc) · 4.46 KB
/
Copy pathfake.go
File metadata and controls
169 lines (127 loc) · 4.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
// This file is part of Camponotus
// Camponotus is free software: see LICENSE.txt for more details.
package telegram
import "io"
// Fake is mocked telegram API, provides dumb response for you.
//
// You should not use this directly, embbed it and overwrite the methods you need instead.
func Fake(me *Victim) API {
return &fake{me}
}
type fake struct {
Me *Victim
}
func (f *fake) AnswerCallbackQuery(query, text string, alert bool) error {
return nil
}
func (f *fake) AnswerInlineQuery(query string, results []InlineQueryResult, opts *InlineQueryOptions) error {
return nil
}
func (f *fake) EditCaption(chat string, msg int, caption, mode string, noPreview bool, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) EditInlineCaption(msg, caption, mode string, noPreview bool, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) EditInlineMarkup(msg string, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) EditInlineText(msg, text, mode string, noPreview bool, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) EditMarkup(chat string, msg int, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) EditText(chat string, msg int, text, mode string, noPreview bool, markup ReplyMarkup) (*Message, error) {
return nil, nil
}
func (f *fake) ForwardMessage(to, from string, silent bool, message int) (*Message, error) {
return nil, nil
}
func (f *fake) GetChat(chat string) (*Victim, error) {
return nil, nil
}
func (f *fake) GetChatAdministrators(chat string) ([]ChatMember, error) {
return []ChatMember{}, nil
}
func (f *fake) GetChatMember(chat string) (*ChatMember, error) {
return nil, nil
}
func (f *fake) GetChatMembersCount(chat string) (int, error) {
return 0, nil
}
func (f *fake) GetFile(file string) (*File, error) {
return nil, nil
}
func (f *fake) GetMe() (*Victim, error) {
return f.Me, nil
}
func (f *fake) GetUpdates(offset, limit, timeout int) ([]Update, error) {
return []Update{}, nil
}
func (f *fake) GetUserProfilePhotos(user, offset, limit int) (*UserProfilePhotos, error) {
return nil, nil
}
func (f *fake) KickChatMember(chat string, user int) error {
return nil
}
func (f *fake) LeaveChat(chat string) error {
return nil
}
func (f *fake) SendAudio(chat, audio string, duration int, performer, title string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendChatAction(chat, action string) error {
return nil
}
func (f *fake) SendContact(chat, phone, firstName, lastName string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendDocument(chat, document, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendLocation(chat string, lat, lng float64, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendMessage(chat, text string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendPhoto(chat, photo, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendSticker(chat, sticker, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendVenue(chat string, lat, lng float64, title, addr, foursq string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendVideo(chat, video string, duration, width, height int, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SendVoice(chat, voice string, duration int, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) SetWebhook(cb string, certificate io.Reader) error {
return nil
}
func (f *fake) UnbanChatMember(chat string, user int) error {
return nil
}
func (f *fake) UploadAudio(chat string, audio io.Reader, duration int, performer, title string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) UploadDocument(chat string, document io.Reader, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) UploadPhoto(chat string, photo io.Reader, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) UploadSticker(chat string, sticker io.Reader, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) UploadVideo(chat string, video io.Reader, duration, width, height int, caption string, opts *Options) (*Message, error) {
return nil, nil
}
func (f *fake) UploadVoice(chat string, voice io.Reader, duration int, opts *Options) (*Message, error) {
return nil, nil
}