Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[INFRA] Tests performance measurement #856

Merged
merged 26 commits into from
Nov 5, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
824fa60
[TEST] performance zoom
aibcmars Oct 28, 2020
0298cfa
[TEST] performance zoom
aibcmars Oct 28, 2020
3d5e605
[TEST] performance zoom, loading, locally available results
aibcmars Nov 2, 2020
facf0b2
[TEST] performance zoom, loading, locally available results
aibcmars Nov 2, 2020
7a7cd3e
[TEST] performance zoom, loading, locally available results
aibcmars Nov 3, 2020
6995d3c
rebased on master
aibcmars Nov 3, 2020
94ed6aa
fix
aibcmars Nov 3, 2020
8021905
add support for 'per os data file'
aibcmars Nov 4, 2020
373ac9a
exclude performance tests from script running e2e
aibcmars Nov 4, 2020
da948a7
exclude only data
aibcmars Nov 4, 2020
d62f510
remove console.log
aibcmars Nov 4, 2020
f9d965b
remove extra cast on page mouse
tbouffard Nov 4, 2020
2253da0
fix lint
aibcmars Nov 4, 2020
541cdd1
add documentation
aibcmars Nov 4, 2020
db317c5
Update docs/development/testing.md
aibcmars Nov 4, 2020
9dddec0
Add perf test results for linux
tbouffard Nov 5, 2020
6ce6906
changed misleading test name
aibcmars Nov 5, 2020
2c32eac
Merge remote-tracking branch 'origin/tests-performance_measurement' i…
aibcmars Nov 5, 2020
e864c84
Update docs/development/testing.md
aibcmars Nov 5, 2020
329a241
switched places results with running tests
aibcmars Nov 5, 2020
e713e42
Merge remote-tracking branch 'origin/tests-performance_measurement' i…
aibcmars Nov 5, 2020
50a493d
add npm command in package json
aibcmars Nov 5, 2020
e2d754c
Update test/e2e/performance/bpmn.load.performance.test.ts
aibcmars Nov 5, 2020
bcbfc6b
fix for mac
aibcmars Nov 5, 2020
7ed899a
MacOs result for performance tests
csouchet Nov 5, 2020
c6e1dc7
Apply suggestions from code review
aibcmars Nov 5, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions docs/development/testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,23 @@ an `HTTP 400 error`.
In that case, configure an alternate load method by referencing the name of the test BPMN diagram in the load configuration
settings.

### Performance tests
For now these tests are defined under `/test/e2e/performance/` as the performance is being measured for complex(e2e) tasks:
- display diagram
aibcmars marked this conversation as resolved.
Show resolved Hide resolved
- zoom in / zoom out loaded diagram

#### Why?
To have visibility if new changes have impact on current performance
aibcmars marked this conversation as resolved.
Show resolved Hide resolved

#### Results
aibcmars marked this conversation as resolved.
Show resolved Hide resolved
The results are under `/test/e2e/performance/data/`
aibcmars marked this conversation as resolved.
Show resolved Hide resolved
Preview is available in the browser, simply open file `/bpmn-visu-js/test/e2e/performance/index.html` in your favourite browser
aibcmars marked this conversation as resolved.
Show resolved Hide resolved

#### Run the performance tests
aibcmars marked this conversation as resolved.
Show resolved Hide resolved
For the moment we have decided to run them manually, in the future they may be run automatically - this however, depends on received results
To run these tests, follow next steps:
1. cd `bpmn-visu-js\test\e2e`
aibcmars marked this conversation as resolved.
Show resolved Hide resolved
2. run `jest --runInBand --detectOpenHandles --testNamePattern=^performance`
aibcmars marked this conversation as resolved.
Show resolved Hide resolved

## Running tests

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/performance/bpmn.load.performance.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const platform = getSimplePlatformName();
const performanceDataFilePath = './performance/data/' + platform + '/data.js';
const metricsArray: Array<PerformanceMetric> = [];

describe.each([1, 2, 3, 4, 5])('diagram navigation performance', run => {
describe.each([1, 2, 3, 4, 5])('load performance', run => {
// to have mouse pointer visible during headless test - add 'showMousePointer=true' to queryParams

const fileName = 'B.2.0';
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/performance/bpmn.navigation.performance.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ const platform = getSimplePlatformName();
const performanceDataFilePath = './performance/data/' + platform + '/data.js';
const metricsArray: Array<PerformanceMetric> = [];

describe.each([1, 2, 3, 4, 5])('diagram navigation performance', run => {
describe.each([1, 2, 3, 4, 5])('zoom performance', run => {
// to have mouse pointer visible during headless test - add 'showMousePointer=true' to queryParams
const bpmnDiagramPreparation = new BpmnDiagramPreparation(new Map([['B.2.0', BpmnLoadMethod.Url]]), { name: 'navigation-diagram', queryParams: [] }, 'performance');

Expand Down