mirror of
https://github.com/go-vgo/robotgo
synced 2026-05-24 02:08:33 +00:00
add more and update test code
This commit is contained in:
parent
f7eec20978
commit
b899d2b4c2
1 changed files with 11 additions and 1 deletions
|
|
@ -27,10 +27,20 @@ func TestGetVer(t *testing.T) {
|
|||
tt.Expect(t, Version, ver)
|
||||
}
|
||||
|
||||
func TestMouse(t *testing.T) {
|
||||
func TestMoveMouse(t *testing.T) {
|
||||
MoveMouse(10, 10)
|
||||
Sleep(1)
|
||||
x, y := GetMousePos()
|
||||
|
||||
tt.Equal(t, 10, x)
|
||||
tt.Equal(t, 10, y)
|
||||
}
|
||||
|
||||
func TestMoveMouseSmooth(t *testing.T) {
|
||||
MoveMouseSmooth(100, 100)
|
||||
Sleep(1)
|
||||
x, y := GetMousePos()
|
||||
|
||||
tt.Equal(t, 100, x)
|
||||
tt.Equal(t, 100, y)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue