Download - Sikuli Google
-
8/2/2019 Sikuli Google
1/54
SIKULIUSING SCREENSHOTS FOR GUIAUTOMATION AND TESTING
Tsung-Hsiang (Sean) Chang, Rob Miller
MIT CSAIL
Collaborator : Tom Yeh
1
12010611
-
8/2/2019 Sikuli Google
2/54
How totell computers what to do?
2
22010611
-
8/2/2019 Sikuli Google
3/54
SHELL SCRIPT
case $rtval in
1) rm -f /tmp/dirip.$$ ; return ;;
255) rm -f /tmp/dirip.$$ ; return ;;
esac
mfile=`cat /tmp/dirip.$$`
if [ -z $mfile ]
then
mfile=`pwd`/*
else
grep "*" /tmp/dirip.$$
if [ $? -eq 1 ]then! mfile=$mfile/*fi
fi
for i in $mfile
do
if [ -f $i ]then! echo "$i Delete?" >> /tmp/finallist.$$fi!
done
3
32010611
-
8/2/2019 Sikuli Google
4/54
4
42010611
-
8/2/2019 Sikuli Google
5/54
GUI AUTOMATION
5
52010611
-
8/2/2019 Sikuli Google
6/54
1
2
3
6
62010611
-
8/2/2019 Sikuli Google
7/54
7
72010611
-
8/2/2019 Sikuli Google
8/54
click click
7
72010611
-
8/2/2019 Sikuli Google
9/54
SIKULI SCRIPT
8
82010611
-
8/2/2019 Sikuli Google
10/54
SIKULI TEST
9
92010611
-
8/2/2019 Sikuli Google
11/54
OUTLINE
Problem - How to refer to a GUI widget?
Sikuli Script - examples and demos
Sikuli Test - demo
Test By Demonstration
Support of testing practices
Conclusions
10
102010611
-
8/2/2019 Sikuli Google
12/54
HOW TO REFER TO A GUI WIDGET?
11
112010611
-
8/2/2019 Sikuli Google
13/54
HOW TO REFER TO A GUI WIDGET?
Abbot
by pre-programmed references
11
112010611
-
8/2/2019 Sikuli Google
14/54
HOW TO REFER TO A GUI WIDGET?
Abbot
by pre-programmed references
Autoit
by absolute locations
11
112010611
-
8/2/2019 Sikuli Google
15/54
Use Screenshots!
12
122010611
-
8/2/2019 Sikuli Google
16/54
TEMPLATE MATCHING
click()
13
132010611
-
8/2/2019 Sikuli Google
17/54
TEMPLATE MATCHING
click()
13
132010611
-
8/2/2019 Sikuli Google
18/54
1
2
3
EXAMPLE 1:
EMPTY TRASH CAN
14
142010611
-
8/2/2019 Sikuli Google
19/54
EX2: FACEBOOK STALKER
15
152010611
-
8/2/2019 Sikuli Google
20/54
EX2: FACEBOOK STALKER
15
152010611
-
8/2/2019 Sikuli Google
21/54
16
162010611
-
8/2/2019 Sikuli Google
22/54
RESTRICT SEARCH REGION
17
172010611
-
8/2/2019 Sikuli Google
23/54
EX3: MUTE SPEAKERS
18
182010611
-
8/2/2019 Sikuli Google
24/54
EX3: MUTE SPEAKERS
18
182010611
-
8/2/2019 Sikuli Google
25/54
SPATIAL OPERATORS
19
192010611
-
8/2/2019 Sikuli Google
26/54
SPATIAL OPERATORS
19
192010611
-
8/2/2019 Sikuli Google
27/54
SPATIAL OPERATORS (2)
20
202010611
-
8/2/2019 Sikuli Google
28/54
EX4: SET IP ADDRESS
21
212010611
-
8/2/2019 Sikuli Google
29/54
VISUAL-EVENT-DRIVEN
PROGRAMMING
22
222010611
-
8/2/2019 Sikuli Google
30/54
VISUAL-EVENT-DRIVEN
PROGRAMMING
22
222010611
-
8/2/2019 Sikuli Google
31/54
SIKULI TEST
23
232010611
-
8/2/2019 Sikuli Google
32/54
VISUAL ASSERTION
Verify appearance
24
242010611
-
8/2/2019 Sikuli Google
33/54
VISUAL ASSERTION
Verify replacement
25
252010611
-
8/2/2019 Sikuli Google
34/54
TEST BY DEMONSTRATION
click
detect changes
26
262010611
-
8/2/2019 Sikuli Google
35/54
Demo
27
272010611
-
8/2/2019 Sikuli Google
36/54
GENERATE ACTION
COMMANDS
mousedown
mouseup
Adown
Aup
bdown
bup
28
282010611
-
8/2/2019 Sikuli Google
37/54
GENERATE ACTION
COMMANDS
low-level events
mousedown
mouseup
Adown
Aup
bdown
bup
28
282010611
-
8/2/2019 Sikuli Google
38/54
GENERATE ACTION
COMMANDS
low-level events
high-levelcommands
click type Ab
mousedown
mouseup
Adown
Aup
bdown
bup
28
282010611
-
8/2/2019 Sikuli Google
39/54
GENERATE ACTION
COMMANDS
low-level events
high-levelcommands
click type Ab
mousedown
mouseup
Adown
Aup
bdown
bup
combine withscreenshots
click
28
282010611
-
8/2/2019 Sikuli Google
40/54
GENERATE ASSERTIONS
click
29
292010611
-
8/2/2019 Sikuli Google
41/54
GENERATE ASSERTIONS
click
1. find differences / manually hint
29
292010611
-
8/2/2019 Sikuli Google
42/54
GENERATE ASSERTIONS
2. group together
click
1. find differences / manually hint
29
292010611
-
8/2/2019 Sikuli Google
43/54
GENERATE ASSERTIONS
2. group together3. combine with assertExist
click
1. find differences / manually hint
29
292010611
-
8/2/2019 Sikuli Google
44/54
GENERATE ASSERTIONS
2. group together3. combine with assertExist
click
1. find differences / manually hint
29
292010611
-
8/2/2019 Sikuli Google
45/54
jUNIT INTEGRATION
30
302010611
-
8/2/2019 Sikuli Google
46/54
TEST-DRIVEN DEVELOPMENT
31
312010611
-
8/2/2019 Sikuli Google
47/54
READABILITY OF CODE
32
322010611
-
8/2/2019 Sikuli Google
48/54
PLATFORM INDEPENDENCE
Works on ANY GUI that can be displayed onWindows/Linux/Mac
Virtual machines
Remote desktop
Mobile simulators: Android, iPhone
Web: Flash, HTML+Javascript
33
332010611
-
8/2/2019 Sikuli Google
49/54
34
342010611
-
8/2/2019 Sikuli Google
50/54
34
342010611
-
8/2/2019 Sikuli Google
51/54
LIMITATIONSTheme Variations
Visibility Constraints
35
352010611
-
8/2/2019 Sikuli Google
52/54
DISCUSSION
Sikuli programs are written against the user interfaceinstead of an API
UI: visible, familiar, always exists API: faster, probably more stable
36
362010611
-
8/2/2019 Sikuli Google
53/54
-
8/2/2019 Sikuli Google
54/54
Thanks!
http://sikuli.csail.mit.edu
New Sikuli 0.10 released.
Follow us on twitter @sikuli
Th k t f di NSF d Q t C t ( t f TP t j t )
or, just google sikuli
http://sikuli.org/http://sikuli.org/