05 test infrastructure

36
Module 05 Test Infrastructure

description

Testing with Visual Studio 2012 Agile TMap

Transcript of 05 test infrastructure

Page 1: 05   test infrastructure

Module 05Test Infrastructure

Page 2: 05   test infrastructure

Topics

Page 3: 05   test infrastructure

The setup and maintenance infrastructure phase aims to provide the required test infrastructure and resources. A distinction is made between test environments, test tools and workplaces. Setting up and maintaining the infrastructure requires very specific expertise. Testers generally have limited knowledge in this area, but are dependent on it. No test can be executed without an infrastructure.

http://www.tmap.net/en/tmap/4-essentials/structured-test-process/acceptance-and-system/infrastructure-phase

The Infrastructure Phase

Page 4: 05   test infrastructure

Test Types

Performance &

Load Tests

Security Tests

‘ility’ Tests

Automated

and ManualManual

AutomatedTools

Automated

Page 5: 05   test infrastructure

Build & Deploy Infrastructure

Functional Test Environment

Load Test Rig

Acceptance Test Environment

Possible Test Environments

Page 6: 05   test infrastructure

Continuous Acceptance Testing

Page 7: 05   test infrastructure

Continuous integration

automatically creates a

build after check-in

Create multiple build definitions

to support various build scenarios

Page 8: 05   test infrastructure

Use build check-in policies to

ensure broken code is fixed

before being checked in

Use either continuous integration builds

or rolling builds with build check-in

policies to ensure quality builds

Page 9: 05   test infrastructure

Configure the gated check-in

build to fail if a test fails, ensuring

the code won’t be checked in

Identify specific test to be run

during the gated check-in build

Page 10: 05   test infrastructure

Configuringfor Unit Testing

Page 11: 05   test infrastructure

Unit Tests, Component Tests

Build Controller andBuild Agent Infrastructure

Is used often and needsto be flexible and fast

Development Test Infrastructure

Page 12: 05   test infrastructure

Use it to retrieve the necessary source code for a build, compile the solution and (if required) execute unit tests and static code analysis tools as part of the build process.

Build Controllers1-1 with Team Project Collection OR 1-* with build agentsPerform lightweight tasks.Can easily be virtualized.

Build Agents1-1 with build controller.Performs heavyweight build tasks.Manage files in source control.Run testsCompile code.Allow load-balanced and/or parallel builds.Can be tagged to spread workload.

Build Infrastructure

Page 13: 05   test infrastructure

Lists builds and provides information about test results, test coverage, code churn and quality notes for each build.

Build Summary Report

Page 14: 05   test infrastructure

Demo

Configuring the BuildInfrastructure for Unit Testing

Page 15: 05   test infrastructure

Configuringfor Functional Testing

Page 16: 05   test infrastructure

“Working Systems”

Manual and automatedtest execution

Planning and Managementof test cases and test plans

Functional Test Infrastructure

Page 17: 05   test infrastructure

Virtual Environments

Lab Management

Working Systems

Page 18: 05   test infrastructure

Use it to retrieve necessary source code for a build, compile the solution and (if required) execute unit tests and static code analysis tools as part of the build process.

Test Controllers1-1 with Team Project Collection | 1-* with test agents.Perform lightweight tasks.Can easily be virtualized.

Test Agents1-1 with test controller.Performs heavyweight test tasks.Run tests Interactive.Collect Data Diagnostic Information.

Build Infrastructure

Page 19: 05   test infrastructure

Configuringfor Acceptance Testing

Page 20: 05   test infrastructure

Real Life Scenarios

“Working systems”

Not always connected tothe rest of the team

Acceptance Tests

Page 21: 05   test infrastructure

Feedback Manager

Exploratory Testing

Alpha/Beta Testing

Lab Management

Testing Working Systems

Page 22: 05   test infrastructure

Test Virtualization

Page 23: 05   test infrastructure

Execute tests in Virtual MachinesLink 1-* VMs with Test Agents to execute tests in different environments.

Low Effort – easy to set upInstall Test Agent on VM.Sync to TFS.Set Up Build Configuration to deploy tests to VM automatically.

Virtualized Test Environments

Page 24: 05   test infrastructure

Execute tests in Virtual Test EnvironmentsA virtual environment is a collection of virtual machines (VMs). Each Virtual Machine in a virtual environment represents a role required for the application that is to be tested, developed or run. Lab Management can be used to start all the virtual machines in a virtual environment to run an application, or test an application.

Automated environment set upLab Management uses System Center Virtual Machine Manager (SCVMM) toallow access to virtual machines or templates in a library as “golden masters”.These golden masters are created by using either Hyper-V or SCVMM.SCVMM is used to deploy the virtual machines and templates tothe environments on the specified host group.

Lab Management

Page 25: 05   test infrastructure

Lab Management Automation

On-premise | Cloud

Page 26: 05   test infrastructure

Create a new environment

using virtual machine

templates in SCVMM

Create an environment

using machines running

on SCVMM

Create new

environments on existing

machines

Page 27: 05   test infrastructure

Quickly choose multiple

test suites to run after

deployment

Choose your environment, and

build, deploy and test in that

environment from a single dialog

Page 28: 05   test infrastructure

Snapshot environments

during manual testing to

increase reproducibility

Spin up virtual test environments from

within Test Manager, or attach a virtual

environment to a manual testing session

Page 29: 05   test infrastructure

Test run results are attached to

specific builds and environments

Collect all the data required

to recreate bugs from virtual

environments

Page 30: 05   test infrastructure

Demo

End-to-End Test WorkflowEnvironment Virtualization

Page 31: 05   test infrastructure

Configuringfor Load Testing

Page 32: 05   test infrastructure

Load Test Clients createvariable load on the target

Load Tests produce lotsof data and information!

Load testing expertise isrequired to interpret results

Load Test Infrastructure

Page 33: 05   test infrastructure

Visual Studio Ultimate can use a computer or a group of computers to generate simulated load for testing, and to run tests remotely and concurrently on several computers. This group of computers consists of a single test controller and one or more test agents. You can use the test controller and test agent to generate more load than a single computer can generate alone or just test remotely.

Load Test Agents

Page 34: 05   test infrastructure

The Cloud can be used for Load Testing – unlimited Load can be generated this way without associated hardware investments.

Agents on Windows Azure

Page 35: 05   test infrastructure

Demo

Load Testing usingWindows Azure

Page 36: 05   test infrastructure