chore: update socks5 message

This commit is contained in:
Bo-Yi Wu 2019-12-07 13:00:35 +08:00
parent 79e531f648
commit 5ac85a3412

View File

@ -408,16 +408,8 @@ func TestProxySendMessage(t *testing.T) {
Config: Config{ Config: Config{
Token: os.Getenv("TELEGRAM_TOKEN"), Token: os.Getenv("TELEGRAM_TOKEN"),
To: []string{os.Getenv("TELEGRAM_TO"), os.Getenv("TELEGRAM_TO") + ":appleboy@gmail.com", "中文ID", "1234567890"}, To: []string{os.Getenv("TELEGRAM_TO")},
Message: []string{"Test Telegram Chat Bot From Travis or Local", "commit message: 『{{ build.message }}』", " "}, Message: []string{"Send message from socks5 proxy URL."},
Photo: []string{"tests/github.png", "1234", " "},
Document: []string{"tests/gophercolor.png", "1234", " "},
Sticker: []string{"tests/github-logo.png", "tests/github.png", "1234", " "},
Audio: []string{"tests/audio.mp3", "1234", " "},
Voice: []string{"tests/voice.ogg", "1234", " "},
Location: []string{"24.9163213 121.1424972", "1", " "},
Venue: []string{"35.661777 139.704051 竹北體育館 新竹縣竹北市", "24.9163213 121.1424972", "1", " "},
Video: []string{"tests/video.mp4", "1234", " "},
Debug: false, Debug: false,
Socks5: os.Getenv("SOCKS5"), Socks5: os.Getenv("SOCKS5"),
}, },
@ -425,14 +417,4 @@ func TestProxySendMessage(t *testing.T) {
err := plugin.Exec() err := plugin.Exec()
assert.NotNil(t, err) assert.NotNil(t, err)
plugin.Config.Format = formatMarkdown
plugin.Config.Message = []string{"Test escape under_score"}
err = plugin.Exec()
assert.NotNil(t, err)
// disable message
plugin.Config.Message = []string{}
err = plugin.Exec()
assert.NotNil(t, err)
} }