Codefresh + BlazeMeter Webinar. Summary & recording posted here- https://codefresh.io/blog/blazemeter-codefresh-webinar-continuous-testing-containerized-applications/
Learn how to containerize your application and set up an automate end-to-end pipeline. Leverage Codefresh to automate your build, test deployments and integrate BlazeMeter into your Continuous Delivery.
3. Agenda
Shifting Testing Left
Intro to Codefresh
Add your application services in Codefresh
Run and test the application manually
Configure an automated pipeline
Blazemeter & Taurus
Using the BlazeMeter Chrome Extension
Modifying the JMeter Script
5. Codefresh
Codefresh is a container platform for Dev
teams. It allows teams to Build, Run, Test
and Deploy containerized applications.
www.codefresh.io
@RazielTabi
b
6. Build & Test Containerized app w Codefresh
Intuitive setup with native support for containers
Automated Unit, Integration, UI and Performance testing
Spin up on-demand Dev/Test environment on any Branch / Pull
Request
containers101/demochat mongo:latest
7. Introduction to BlazeMeter and Taurus
BlazeMeter: Platform for executing load tests at scale
Cloud-based load generators
Intuitive reporting
Open Source DNA
Taurus: Open Source Test Development and Execution
Execute existing open source load test scripts: JMeter / Selenium / Gatling / etc…
and / or
8. Test Development: Record with BlazeMeter Extension
Works with Google Chrome Web Browser and
BlazeMeter Account
Easy to Install, Easy to Use
Click the Record Button to Start Capture
Captures All Requests from the Browser,
Including AJAX
Navigate Through the App to Build the Test
Plan
Stop Recorder and Save Recordings as JMX
9. Test Development: Modify the JMeter Script
Clean Up Extraneous Requests
Parameterize the Script
Replace static post data with
${variables}
Include a CSV file to populate the
variables
Each thread or iteration will
use different values.
Use Post Processors to Capture
Session Tokens
10. Test Development: Convert to Taurus
Use jmx2yaml
Utility to
Convert JMeter
files to more
readable YAML
Optionally Trim
Out Recorded
Headers for
Additional
Readability
---
execution:
- concurrency: 20
iterations: 10
scenario: Thread Group
scenarios:
Thread Group:
default-address: http://AUT:5000
data-sources:
- accounts.csv
requests:
- body:
display-name: ${account}
email: ${email}
first-name: ${fname}
last-name: ${lname}
password: ${password}
password-confirm: ${password}
username: ${account}
label: register
method: POST
url: /account/register
- label: login
body:
password: ${password}
username: ${account}
method: POST
url: /account/login
- label: emotes
method: GET
url: /extras/emotes
- label: replacements
method: GET
url: /extras/replacements
- label: chat
method: GET
url: /socket.io/?EIO=3&transport=polling&t=1477932100202-0
extract-regexp:
sid:
default: NO_MATCH
match-no: 1
regexp: '"sid":"(.+)","'
template: $1$
- label: chat session
method: GET
url: /socket.io/?EIO=3&transport=polling&t=1477932100505-1&sid=${sid}
- label: chat session
body: 21:420["account:whoami"]
method: POST
url: /socket.io/?EIO=3&transport=polling&t=1477932100655-2&sid=${sid}
- label: chat session
method: GET
url: /socket.io/?EIO=3&transport=polling&t=1477932100711-3&sid=${sid}
- label: logout
method: GET
url: /logout
store-cache: true
store-cookie: true
use-dns-cache-mgr: false
11. Test Development: Create Container for Taurus
Create Dockerfile to Build
Taurus Container with
Script and CSV
Included
FROM debian:latest
RUN apt-get update
RUN apt-get install -y python default-jre-headless python-tk python-
pip python-dev libxml2-dev libxslt-dev zlib1g-dev
RUN pip install bzt
RUN pip install --upgrade bzt
COPY . /scripts
WORKDIR /scripts
CMD ["bzt" , "letschat.yml", "-report"]