You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
843 B
32 lines
843 B
package juhe_test
|
|
|
|
import (
|
|
"yunyan/sys/juhe"
|
|
"fmt"
|
|
"testing"
|
|
)
|
|
|
|
// 查询简单天气信息
|
|
func Test_sys_simpleWeather(t *testing.T) {
|
|
sys, _ := juhe.NewSys(juhe.SetSimpleWeather_ApiKey("efd8f9f391d73d7337344d26ee93d173"))
|
|
result, err := sys.SimpleWeather("上海")
|
|
fmt.Printf("result:%v err:%v", result, err)
|
|
}
|
|
|
|
// 查询股票代码
|
|
func Test_sys_financebygid(t *testing.T) {
|
|
sys, _ := juhe.NewSys(juhe.SetFinance_ApiKey("50a101c9c5ff7c967598cea4bcc8ebbd"))
|
|
sys.Financebygid("sh601009")
|
|
}
|
|
|
|
// 查询股票代码
|
|
func Test_sys_financebytype(t *testing.T) {
|
|
sys, _ := juhe.NewSys(juhe.SetFinance_ApiKey("50a101c9c5ff7c967598cea4bcc8ebbd"))
|
|
sys.Financebytype("0")
|
|
}
|
|
|
|
// 查询股票代码
|
|
func Test_sys_toutiao(t *testing.T) {
|
|
sys, _ := juhe.NewSys(juhe.SetToutiao_ApiKey("035a1d052001f6f87358a159e7c44575"))
|
|
sys.Toutiao("top")
|
|
}
|
|
|