9 Load Testing Best Practices

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 18

Load Testing

Best Practices
(Don’t Make These
Mistakes)
TEST GUILD
One of the most
misunderstood
parts of
performance testing
is load testing.
Performance Testing

Load Testing

There are are many


types of tests that
make up
“performance
testing”
So what is a

LOAD TEST
“A load test is many concurrent
users running the same program
to see whether a system
infrastructure handles the load
without compromising
functionality or performance.”

Definition from an old Mercury


Interactive LoadRunner workbook
“A load test is a specific sub-family of a
performance test.
Sometimes I say that performance testing
would be an equivalent of Microsoft Office
and a load test is Word.
Word just a component of Office. Word
is heavily used, together with Excel.
They are probably the two most
heavily used components of Office. But
it's not Office.”

LEANDRO MELENDEZ
Sr Performo
Now that we are
clearer on what load
testing is, here are nine
strategies to think about
when preparing to do a
load test.
Targeting the
Right Workload

First, don't test your


application on a large scale
without actually needing to
do so. There’s no need to
stress your platform
beyond what is actually
expected.
Load Generator
Readiness
“Load generators” are the
computers that run your virtual
user tests.

A virtual user is a script that acts like


a real user would when making
simultaneous requests to your
application & systems under test.

This is usually done by


emulating browsers
communicating with the
backend of your system.
Scripting
It's not enough just to create a
test that will mimic real-world
scenarios.
You also need to ensure that
your scripts are not
overloading the test tool itself.
Think Time
All tools should have some logic of
how to add think time by specifying
how many seconds you want the
virtual user to wait.
Think time is useful to mimic
the right workload according
to the real behavior of the
virtual user. Just like a
functional Selenium test,
it's also advised to use
think time
rather than a
sleep function.
Ramp Up and
Ramp Down Time
If you can afford to make the
ramp-up and ramp-down time
longer, then do so.
It’s a good practice to have a
ramp-up time when running a
load test, as it will take some
time before your test reaches a
steady state.
Monitoring and
Diagnostics
Capturing deep diagnostics info
during a normal test means that a lot
of data will be captured. But for an
extended test with many virtual
users, the data captured can be
staggering. The side effect of this can
be that your test tooling might have
a challenge trying to cope with all
this information.
The same goes for
performance
monitoring.
Workload
Scheduling
Workload scheduling refers to
how fast you plan to ramp up and
ramp down your virtual users.
ASK THESE QUESTIONS:
What will the impact on the
load generators be?
What is the effect that it's
going to have on the
application or
applications itself?
GUI Virtual Users
GUI users are heavier virtual users,
and their footprint is more
substantial. It's critical to know how
many GUI users you can run on your
load generator.

You should be ready in advance to


avoid redundant failures and to
prepare the right amount
of load generators,
balancing the
workload
across them.
Analyze Test Data
Keep in mind that faulty analysis of
your software data will produce faulty
results. Don’t jump to conclusions
without properly analyzing the data.
It takes experience and skill to extract
relevant conclusions from the data
produced by a load test, so don’t take
this step lightly.
Click the link above
and read

TEST GUILD's
comprehensive
blog post about
Load Testing
Best Practices.
TEST GUILD
for more
PERFORMANCE
TESTING
tips!!!

You might also like