Skip to content

Commit 76b93a9

Browse files
Merge pull request atlassian#552 from atlassian/release/4.1.0
Release 4.1.0
2 parents 1b49bcb + 27087a0 commit 76b93a9

File tree

71 files changed

+1655
-1032
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+1655
-1032
lines changed

Dockerfile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# name: atlassain/dcapt
1+
# name: atlassian/dcapt
22
# working dir: dc-app-performance-toolkit
3-
# build: docker build -t atlassain/dcapt .
3+
# build: docker build -t atlassian/dcapt .
44
# bzt run: docker run --shm-size=4g -v "$PWD:/dc-app-performance-toolkit" atlassian/dcapt jira.yml
55
# interactive run: docker run -it --entrypoint="/bin/bash" -v "$PWD:/dc-app-performance-toolkit" atlassian/dcapt
66

@@ -9,12 +9,16 @@ FROM blazemeter/taurus
99
ENV APT_INSTALL="apt-get -y install --no-install-recommends"
1010

1111
RUN apt-get -y update \
12-
&& $APT_INSTALL vim git openssh-server python3.8-dev python3-pip google-chrome-stable \
12+
&& $APT_INSTALL vim git openssh-server python3.8-dev python3-pip wget \
1313
&& update-alternatives --install /usr/bin/python python /usr/bin/python3.8 1 \
1414
&& python -m pip install --upgrade pip \
1515
&& python -m pip install --upgrade setuptools \
1616
&& apt-get clean
1717

18+
RUN wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb \
19+
&& $APT_INSTALL ./google-chrome-stable_current_amd64.deb \
20+
&& rm -rf ./google-chrome-stable_current_amd64.deb
21+
1822
COPY requirements.txt /tmp/requirements.txt
1923
RUN pip install --no-cache-dir -r /tmp/requirements.txt
2024

README.md

Lines changed: 60 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@ This repository contains Taurus scripts for performance testing of Atlassian Dat
55

66
## Supported versions
77
* Supported Jira versions:
8-
* Jira [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `8.13.3`, `8.5.11`
8+
* Jira [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `8.13.4`, `8.5.12`
99

1010
* Supported Jira Service Management versions:
11-
* Jira Service Management [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `4.13.2`, `4.5.10`
11+
* Jira Service Management [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `4.13.4`, `4.5.12`
1212

1313
* Supported Confluence versions:
14-
* Confluence [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `7.4.6`
14+
* Confluence [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `7.4.8`
1515
* Confluence Platform release: `7.0.5`
1616

1717
* Supported Bitbucket Server versions:
18-
* Bitbucket Server [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `7.6.2`, `6.10.7`
18+
* Bitbucket Server [Long Term Support release](https://confluence.atlassian.com/enterprise/atlassian-enterprise-releases-948227420.html): `7.6.4`, `6.10.9`
1919
* Bitbucket Server Platform release: `7.0.5`
2020

2121
## Support
@@ -27,25 +27,34 @@ In case of technical questions, issues or problems with DC Apps Performance Tool
2727
* Python 3.6-3.8 and pip
2828
* JDK 8
2929
* Google Chrome web browser
30-
* Git client (only for Bitbucket Server)
30+
* Git client (only for Bitbucket DC)
3131

3232
Please make sure you have a version of Chrome browser that is compatible with [ChromeDriver](http://chromedriver.chromium.org/downloads) version set in app/$product.yml file (modules->selenium->chromedriver->version).
3333

3434
If a first part of ChromeDriver version does not match with a first part of your Chrome browser version, update Chrome browser or set compatible [ChromeDriver](http://chromedriver.chromium.org/downloads) version in .yml file.
3535

36-
### macOS/Linux
37-
Make sure that you have [Python](https://www.python.org/downloads/) (see [dependencies](#dependencies) section for supported versions), pip, and [JDK 8](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) installed:
36+
### macOS setup
37+
Make sure that you have:
38+
* [Python](https://www.python.org/downloads/) (see [dependencies](#dependencies) section for supported versions)
39+
* pip
40+
* [JDK 8](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) installed
41+
* XCode Command Line Tools
42+
* Google Chrome web browser
3843
```
3944
python3 --version
4045
pip --version
4146
java -version
47+
# command to check if XCode Command Line Tools installed
48+
xcode-select --print-path
49+
# or command to install if XCode Command Line Tools
50+
xcode-select --install
4251
```
43-
For Bitbucket Server check that [Git](https://git-scm.com/downloads) is installed:
52+
For Bitbucket DC check that [Git](https://git-scm.com/downloads) is installed:
4453
```
4554
git --version
4655
```
4756

48-
We recommend using virtualenv for Taurus.
57+
We recommend using [virtualenv](https://virtualenv.pypa.io/en/latest/) for Taurus.
4958

5059
1. Install virtualenv with pip:
5160
```
@@ -64,7 +73,47 @@ source venv/bin/activate
6473
pip install -r requirements.txt
6574
```
6675

67-
### Windows
76+
### Linux setup
77+
Make sure that you have:
78+
* [Python](https://www.python.org/downloads/) (see [dependencies](#dependencies) section for supported versions)
79+
* pip
80+
* [JDK 8](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) installed
81+
* Python developer package (e.g. `python3.8-dev` package for Python3.8)
82+
* Google Chrome web browser
83+
```
84+
python3 --version
85+
pip --version
86+
java -version
87+
```
88+
For Bitbucket DC check that [Git](https://git-scm.com/downloads) is installed:
89+
```
90+
git --version
91+
```
92+
We recommend using [virtualenv](https://virtualenv.pypa.io/en/latest/) for Taurus. See example setup below.
93+
94+
## Example setup for clean Ubuntu 18.04
95+
JDK setup (if missing):
96+
```
97+
sudo apt-get update
98+
sudo apt-get install -y openjdk-8-jre-headless
99+
```
100+
Chrome setup (if missing):
101+
```
102+
sudo apt-get update
103+
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
104+
sudo apt-get install -y ./google-chrome-stable_current_amd64.deb
105+
```
106+
Python and virtualenv setup:
107+
```
108+
sudo apt-get update
109+
sudo apt-get -y install python3.8-dev python3-pip virtualenv
110+
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.8 1
111+
virtualenv venv -p python
112+
source venv/bin/activate
113+
pip install -r requirements.txt
114+
```
115+
116+
### Windows setup
68117
#### Installing Taurus manually
69118
Make sure you have [Python](https://www.python.org/downloads/) (see [dependencies](#dependencies) section for supported versions), pip, and [JDK 8](https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) installed:
70119
```
@@ -89,7 +138,7 @@ Otherwise, download it from [Microsoft Visual C++ Build Tools:](https://visualst
89138

90139
Setup [Windows 10 SDK](https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk/)
91140

92-
We recommend using virtualenv for Taurus.
141+
We recommend using [virtualenv](https://virtualenv.pypa.io/en/latest/) for Taurus.
93142
1. Install virtualenv with pip:
94143
```
95144
pip install virtualenv

app/bitbucket.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ modules:
8585
httpsampler.ignore_failed_embedded_resources: "true"
8686
selenium:
8787
chromedriver:
88-
version: "88.0.4324.27" # Supports Chrome version 88. You can refer to http://chromedriver.chromium.org/downloads
88+
version: "89.0.4389.23" # Supports Chrome version 89. You can refer to http://chromedriver.chromium.org/downloads
8989
reporting:
9090
- data-source: sample-labels
9191
module: junit-xml

app/confluence.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ modules:
109109
httpsampler.ignore_failed_embedded_resources: "true"
110110
selenium:
111111
chromedriver:
112-
version: "88.0.4324.27" # Supports Chrome version 88. You can refer to http://chromedriver.chromium.org/downloads
112+
version: "89.0.4389.23" # Supports Chrome version 89. You can refer to http://chromedriver.chromium.org/downloads
113113
reporting:
114114
- data-source: sample-labels
115115
module: junit-xml

app/extension/bitbucket/extension_ui.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
from selenium_ui.base_page import BasePage
66
from selenium_ui.conftest import print_timing
7+
from selenium_ui.bitbucket.pages.pages import LoginPage, GetStarted
78
from util.conf import BITBUCKET_SETTINGS
89

910

@@ -14,6 +15,23 @@ def app_specific_action(webdriver, datasets):
1415
project_key = rnd_repo[1]
1516
repo_slug = rnd_repo[0]
1617

18+
# To run action as specific user uncomment code bellow.
19+
# NOTE: If app_specific_action is running as specific user, make sure that app_specific_action is running
20+
# just before test_2_selenium_logout action
21+
22+
# @print_timing("selenium_app_specific_user_login")
23+
# def measure():
24+
# def app_specific_user_login(username='admin', password='admin'):
25+
# login_page = LoginPage(webdriver)
26+
# login_page.delete_all_cookies()
27+
# login_page.go_to()
28+
# login_page.set_credentials(username=username, password=password)
29+
# login_page.submit_login()
30+
# get_started_page = GetStarted(webdriver)
31+
# get_started_page.wait_for_page_loaded()
32+
# app_specific_user_login(username='admin', password='admin')
33+
# measure()
34+
1735
@print_timing("selenium_app_custom_action")
1836
def measure():
1937

app/extension/confluence/extension_locust.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import re
2-
from locustio.common_utils import init_logger, confluence_measure
2+
from locustio.common_utils import init_logger, confluence_measure, run_as_specific_user # noqa F401
33

44
logger = init_logger(app_type='confluence')
55

66

77
@confluence_measure("locust_app_specific_action")
8+
# @run_as_specific_user(username='admin', password='admin') # run as specific user
89
def app_specific_action(locust):
910
r = locust.get('/app/get_endpoint', catch_response=True) # call app-specific GET endpoint
1011
content = r.content.decode('utf-8') # decode response content

app/extension/confluence/extension_ui.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
from selenium_ui.base_page import BasePage
66
from selenium_ui.conftest import print_timing
7+
from selenium_ui.confluence.pages.pages import Login, AllUpdates
78
from util.conf import CONFLUENCE_SETTINGS
89

910

@@ -12,6 +13,25 @@ def app_specific_action(webdriver, datasets):
1213
if datasets['custom_pages']:
1314
app_specific_page_id = datasets['custom_page_id']
1415

16+
# To run action as specific user uncomment code bellow.
17+
# NOTE: If app_specific_action is running as specific user, make sure that app_specific_action is running
18+
# just before test_2_selenium_z_log_out
19+
# @print_timing("selenium_app_specific_user_login")
20+
# def measure():
21+
# def app_specific_user_login(username='admin', password='admin'):
22+
# login_page = Login(webdriver)
23+
# login_page.delete_all_cookies()
24+
# login_page.go_to()
25+
# login_page.wait_for_page_loaded()
26+
# login_page.set_credentials(username=username, password=password)
27+
# login_page.click_login_button()
28+
# if login_page.is_first_login():
29+
# login_page.first_user_setup()
30+
# all_updates_page = AllUpdates(webdriver)
31+
# all_updates_page.wait_for_page_loaded()
32+
# app_specific_user_login(username='admin', password='admin')
33+
# measure()
34+
1535
@print_timing("selenium_app_custom_action")
1636
def measure():
1737

app/extension/jira/extension_locust.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import re
2-
from locustio.common_utils import init_logger, jira_measure
2+
from locustio.common_utils import init_logger, jira_measure, run_as_specific_user # noqa F401
33

44
logger = init_logger(app_type='jira')
55

66

77
@jira_measure("locust_app_specific_action")
8+
# @run_as_specific_user(username='admin', password='admin') # run as specific user
89
def app_specific_action(locust):
910
r = locust.get('/app/get_endpoint', catch_response=True) # call app-specific GET endpoint
1011
content = r.content.decode('utf-8') # decode response content

app/extension/jira/extension_ui.py

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
from selenium_ui.base_page import BasePage
66
from selenium_ui.conftest import print_timing
7+
from selenium_ui.jira.pages.pages import Login
78
from util.conf import JIRA_SETTINGS
89

910

@@ -12,13 +13,32 @@ def app_specific_action(webdriver, datasets):
1213
if datasets['custom_issues']:
1314
issue_key = datasets['custom_issue_key']
1415

16+
# To run action as specific user uncomment code bellow.
17+
# NOTE: If app_specific_action is running as specific user, make sure that app_specific_action is running
18+
# just before test_2_selenium_z_log_out action
19+
#
20+
# @print_timing("selenium_app_specific_user_login")
21+
# def measure():
22+
# def app_specific_user_login(username='admin', password='admin'):
23+
# login_page = Login(webdriver)
24+
# login_page.delete_all_cookies()
25+
# login_page.go_to()
26+
# login_page.set_credentials(username=username, password=password)
27+
# if login_page.is_first_login():
28+
# login_page.first_login_setup()
29+
# if login_page.is_first_login_second_page():
30+
# login_page.first_login_second_page_setup()
31+
# login_page.wait_for_page_loaded()
32+
# app_specific_user_login(username='admin', password='admin')
33+
# measure()
34+
1535
@print_timing("selenium_app_custom_action")
1636
def measure():
17-
1837
@print_timing("selenium_app_custom_action:view_issue")
1938
def sub_measure():
2039
page.go_to_url(f"{JIRA_SETTINGS.server_url}/browse/{issue_key}")
2140
page.wait_until_visible((By.ID, "summary-val")) # Wait for summary field visible
2241
page.wait_until_visible((By.ID, "ID_OF_YOUR_APP_SPECIFIC_UI_ELEMENT")) # Wait for you app-specific UI element by ID selector
2342
sub_measure()
2443
measure()
44+

app/extension/jsm/extension_locust_agents.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import re
2-
from locustio.common_utils import init_logger, jsm_agent_measure
2+
from locustio.common_utils import init_logger, jsm_agent_measure, run_as_specific_user # noqa F401
33

44
logger = init_logger(app_type='jsm')
55

66

77
@jsm_agent_measure('locust_agent_app_specific_action')
8+
# @run_as_specific_user(username='admin', password='admin') # run as specific user
89
def app_specific_action(locust):
910
r = locust.get('/app/get_endpoint', catch_response=True) # call app-specific GET endpoint
1011
content = r.content.decode('utf-8') # decode response content

0 commit comments

Comments
 (0)