-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgetstar_test.go
51 lines (43 loc) · 971 Bytes
/
getstar_test.go
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
package doushu
import (
"testing"
)
func TestGetMingGong(t *testing.T) {
if GetMinggong(Zhengyue, Zi) != Yin {
t.Error("GetMingGong error")
}
}
func TestGetWuxingju(t *testing.T) {
if GetWuxingju(Jia, Zi) != Shui2ju {
t.Error("GetMingGong error")
}
}
func TestGetZiwei(t *testing.T) {
if GetZiwei(Mu3ju, Chuyi) != Chen {
t.Error("GetMingGong error")
}
}
func TestGetZiweiStars(t *testing.T) {
poses, star := GetZiweiStars(You)
t.Log(star.String(), poses[0].String())
if poses[0] != Shen {
t.Fatal("GetZiweiStars error")
}
}
func TestGetHuoStar(t *testing.T) {
if GetHuoStar(Si, Hai) != Yin {
t.Fatal(GetHuoStar(Si, Hai))
}
}
func TestGetChangshengStars(t *testing.T) {
poses, star := GetChangsheng12Stars(Jin4ju, Yang, Nv)
t.Log(star.String(), poses[0].String())
if poses[0] != Si {
t.Fatal("GetZiweiStars error")
}
}
func TestGetXiaoxianStart(t *testing.T) {
if GetXiaoxianStart(Shen) != Xu {
t.Fatal(GetXiaoxianStart(Shen))
}
}