benefits from aats

Post on 21-Jan-2018

62 Views

Category:

Technology

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Test Automation Benefits

“There’s no place for human beings to be doing regression testing manually.”

-Jez Humble

Save resources

Example:

More testing during development

Speedier deployments• Faster through the testing phase

• More likely the 1st deployment will be correct

Why don’t more people use them?

Reasons used for not having them

• Extra time to create them

• Learning Curve/Experience

• They can be more code than the actual software

• More to maintain

• They take time to run

Overcoming the Impediments

Browser API Services Domain DAL

• Limited paths• Smoke• Slow, hardest to maintain• More test setup required

than unit

• Closely-collaborating components

• Complex interactions, many permutations faster to test

Browser automation

JavaScript unit tests

API-level AATs (integration tests)

Integration tests

Integration tests

Unit testsUnit tests

• Complex query permutation

• Logic permutations

• Fastest • Isolated

• Fast• Checks any

UI• Processes /

preparing and what is sent to the API is ok

• Check business requirements

• Limited paths• Slower than

unit• More test

setup required than unit

Develop a Testing Strategy

Know what tests to write when

• Balance high # of unit tests + selected end-to-end & acceptance

• AATs should be a small portion of your test suite• Is your new feature entirely new?

Acceptance

Component

Unit

Black box

White box

End-to-end Business facing

Localized Technology facing

Testing Strategies

The First Tests…

• Find the most crucial and most changed functionality.

• Determine if the code is testable. If not, start with black box end-to-end tests.

• Once code is being covered by tests in some way, start refactoring it so unit tests can be written.

When a bug isn’t caught

• See why bug got through the existing unit/integration tests

• Add unit, integration tests for it

Unit

Test First Approach

• Create tests up front. Helps guide code creation and makes it easier to think through the functionality, and tests.

• Start using TDD when appropriate

Champion Testing

• Show the data on how automated testing reduces bugs, results in better architected code, and saves time and money.

• Coach team members who don’t have enough experience

• Pair program

• Review open source projects test strategies and code

top related