automated testing & test tools

25
1 Automated Testing & Test Tools Apirada Thadadech

Upload: gabrielle-moreau

Post on 02-Jan-2016

36 views

Category:

Documents


4 download

DESCRIPTION

Automated Testing & Test Tools. Apirada Thadadech. The Benefits of Automation and Tools Test Tools Software Test Automation Random Testing: Monkeys and Gorillas Realities of Using Test Tools and Automation. Contents. The Benefits of Automation and Tools. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Automated Testing & Test Tools

1

Automated Testing & Test Tools

Apirada Thadadech

Page 2: Automated Testing & Test Tools

Apirada Thadadech

2

Contents

The Benefits of Automation and Tools

Test Tools

Software Test Automation

Random Testing: Monkeys and Gorillas

Realities of Using Test Tools and

Automation

Page 3: Automated Testing & Test Tools

Apirada Thadadech

3

The Benefits of Automation and Tools

•The code test fix loop get repeat several times before the software is released.

•Might need Many time to run the tests and check the bugs that found in previous test runs were indeed fixed and no new bugs.

Software test tool and automation can help to solve those problem

Page 4: Automated Testing & Test Tools

Apirada Thadadech

4

The principle attributes of tools and automation:

Speed. Might average test case every 5 seconds.

Efficience. During running test case by test tool, have time

for test planning and thinking up new test.

Accuracy and Precision. A test tool will perform the

same test and check the result perfectly.

Relentlessness. Test tools and automation never tire or

give up

Page 5: Automated Testing & Test Tools

Apirada Thadadech

5

reminder

Software test tools are not a substitute for

software testers, but they just help software

testers perform their jobs better.

Page 6: Automated Testing & Test Tools

Apirada Thadadech

6

Test Tools

Test tool work as Black- box testing. They could

perform software tests without having to set up a real-

real scenario, they don’t need to understand how the

tool works.

Test tool could be set up the monitor and modify the

raw communications that occurs among those million

computers(testing networking software)

Test tool could be set up to monitor and modify the

raw communications that occurs among those million

computer seem white-box skills and knowledge of the

low-level protocol to effectively use the tool.

Page 7: Automated Testing & Test Tools

Apirada Thadadech

7

Types of test tool

InvasiveInvasive

A tool is used only to

monitor and examine

the software without

modifying

Non-invasiveNon-invasive

A tool modifies the

program code or

manipulates the

operating environment

Page 8: Automated Testing & Test Tools

Apirada Thadadech

8

Test Tool Type

Viewers and Monitors Test tool allow tester to see

details of software’s operation that they wouldn’t normally

be able to see.

Drivers are tools used to control and operate the software

being tested, such as batch file, software that testing

requires large amounts of data to be entered for test.

Stubs is like driver, but stubs are essentially the opposite

of driver in that they don’t control operate the software

being tested. Such as sent data to printer, you can test it is

to enter data, print it and look at the result paper printout.

Page 9: Automated Testing & Test Tools

Apirada Thadadech

9

Viewers and Monitors

Computer #1 Computer #2

Software under test Software under test

Communications line

Computer #3

Viewer test tool

Tapped line

Page 10: Automated Testing & Test Tools

Apirada Thadadech

10

Stress and Load Tools

Stress ToolStress Tool is The Stress

program allows you to

individually set the

amounts of memory. Disk

space, files and other

resources available to the

software running on the

machine.

Load ToolLoad Tool is similar to stress tool

but it run on Web servers to

load them down by simulating

a set number of connections.

Such as it check that 10.000

simultaneous users and 1

million hits a day can be

handled without showing

response times.

There are problems about available memory and disk space when the system run many programs in the same time, such as running word processing and copy file to fill up….and so on.

Page 11: Automated Testing & Test Tools

Apirada Thadadech

11

Software Test Automation

Software test automation is software that

could be combined, started, and run with

little or no intervention from tester.

Page 12: Automated Testing & Test Tools

Apirada Thadadech

12

Types of automation Macro recording and payback

Programmed Macros

Fully Programmable Automated Testing

Tools

Page 13: Automated Testing & Test Tools

Apirada Thadadech

13

Macro recording and payback The Most basic type of test automation is

recording your keyboard and mouse actions

as you run your tests for first time and then

playing them back when you need to run

them again

Page 14: Automated Testing & Test Tools

Apirada Thadadech

14

The Option in Macro recording and playback Name Name : Macro name provides a way to identify it later. RepetitionsRepetitions: Great way to find bugs. You can set the number of

times the macro will repeat or loop when it runs. TriggerTrigger : you can set how the macro is started, can be by a hot

key. What’s capturedWhat’s captured: you can select to capture as ketstrokes or

mouse action. Play back speedPlay back speed: it can set play back from 20 % slower to 500% Playback positionPlayback position: determines when mouse movements and

clicks should be absolute or relative to a certain window onescreen

Page 15: Automated Testing & Test Tools

Apirada Thadadech

15

Note:Note:

Recording and playing back macros is a

popular means to automate simple testing

tasks. Its also a good place to start for

testers learning how to automate their.

Page 16: Automated Testing & Test Tools

Apirada Thadadech

16

Programmed Macros

Programmed macros are a step up in

evolution from the simple record and

playback variety.

Page 17: Automated Testing & Test Tools

Apirada Thadadech

17

Simple macro program

1: calculator test #2

2: <<execute:c\windows\calc.exe-->>

3: <<lookfor : calculator –secs: 5 -- >>

4: 123 – 100 =

5: << prompt : the answer should be 23 >>

6: << close: calculator>>

A Simple Macro that performs a test on the Windows Calculator

Page 18: Automated Testing & Test Tools

Apirada Thadadech

18

Random Testing: Monkeys and Gorillas

Test Monkey :

The idea that you had a million

monkeys typing on a million

keyboards for a million years.

The use of test monkey to simulate how your customers will use your software in no way insinuates that computer users are related to apes.

Page 19: Automated Testing & Test Tools

Apirada Thadadech

19

Test monkeys

Dump monkeys

Semi-Smart monkeys

Smart Monkeys

Page 20: Automated Testing & Test Tools

Apirada Thadadech

20

Dump Monkeys

A dump monkey doesn’t know anything

about the software being tested; it just

clicks or types randomly.

1: randomize timer

2: for I = 1 to 10000

3: play “{click “+str$(int(RND*640))+”, “+STR$(RND*480))+”}”

4: play CHR$ (RND*256)

5: Next i

Page 21: Automated Testing & Test Tools

Apirada Thadadech

21

Remember

The monkey is doing absolutely no

verification. It just clicks and types

until one of two things happens-

either it finishes its loop or the

software or the operating system

crashes.

Page 22: Automated Testing & Test Tools

Apirada Thadadech

22

Note

If you don’t believe that a dumb

monkey can possibly find a serious bug, try

running one on your favorite computer

game or multimedia program.

Page 23: Automated Testing & Test Tools

Apirada Thadadech

23

It doesn’t seem to make sense that

simple random clicking and typing could

find a bug, but it does for a couple

reasons:

Given enough time and attempts.

With its continuous repetition and use.

Page 24: Automated Testing & Test Tools

Apirada Thadadech

24

Semi-Smart Monkeys

Page 25: Automated Testing & Test Tools

Apirada Thadadech

25

Realities of Using Test Tools and Automation

•The Software changes. Specifications are never fixed.

•There’s no substitute for the human eye and intuition.

•Verification is hard to do

•It is easy to rely on automation too much.

•Don’t spend so much time working on tools and automation that you fail to test the software.

•If you’re writing macros, developing a tool, or programming a monkey, you are doing development work.

•Some tools are invasive and can cause the software being tested to improperly fail.