Fix/143 image comparison (#150)
* Attach squish server config to test report * Fix image comparison on CI #143 * Fix failed image comparison #143 * List branches added #144
This commit is contained in:
parent
87fc8cbb38
commit
e768492703
|
@ -7,3 +7,6 @@ configs/_local.py
|
||||||
*.pyc
|
*.pyc
|
||||||
|
|
||||||
tmp/
|
tmp/
|
||||||
|
|
||||||
|
*.DS_Store
|
||||||
|
|
||||||
|
|
|
@ -20,6 +20,19 @@ pipeline {
|
||||||
}
|
}
|
||||||
|
|
||||||
parameters {
|
parameters {
|
||||||
|
|
||||||
|
gitParameter(
|
||||||
|
branch: '',
|
||||||
|
branchFilter: 'origin/(.*)',
|
||||||
|
defaultValue: 'master',
|
||||||
|
description: 'Git branch to checkout.',
|
||||||
|
name: 'GIT_REF',
|
||||||
|
quickFilterEnabled: false,
|
||||||
|
selectedValue: 'DEFAULT',
|
||||||
|
sortMode: 'ASCENDING_SMART',
|
||||||
|
tagFilter: '*',
|
||||||
|
type: 'PT_BRANCH'
|
||||||
|
)
|
||||||
string(
|
string(
|
||||||
name: 'BUILD',
|
name: 'BUILD',
|
||||||
description: 'Paste a number of PR that you want to test.',
|
description: 'Paste a number of PR that you want to test.',
|
||||||
|
@ -27,17 +40,17 @@ pipeline {
|
||||||
)
|
)
|
||||||
string(
|
string(
|
||||||
name: 'TEST_NAME',
|
name: 'TEST_NAME',
|
||||||
description: 'Paste test name/part of test name to run specific test',
|
description: 'Paste test name/part of test name to run specific test.',
|
||||||
defaultValue: ''
|
defaultValue: ''
|
||||||
)
|
)
|
||||||
string(
|
string(
|
||||||
name: 'TEST_SCOPE',
|
name: 'TEST_SCOPE',
|
||||||
description: 'Paste tag to run specific scope of tests',
|
description: 'Paste tag to run specific scope of tests.',
|
||||||
defaultValue: ''
|
defaultValue: ''
|
||||||
)
|
)
|
||||||
string(
|
string(
|
||||||
name: 'TESTRAIL_RUN_ID',
|
name: 'TESTRAIL_RUN_ID',
|
||||||
description: 'Test run ID in Test Rail',
|
description: 'Test run ID in Test Rail.',
|
||||||
defaultValue: ''
|
defaultValue: ''
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -82,6 +95,7 @@ pipeline {
|
||||||
autoDisplayName: true,
|
autoDisplayName: true,
|
||||||
parallelBuild: true,
|
parallelBuild: true,
|
||||||
screen: '1920x1080x24',
|
screen: '1920x1080x24',
|
||||||
|
additionalOptions: '-dpi 1'
|
||||||
]) { script {
|
]) { script {
|
||||||
sh "fluxbox &"
|
sh "fluxbox &"
|
||||||
env.TESTRAIL_USR = "${CREDS_USR}"
|
env.TESTRAIL_USR = "${CREDS_USR}"
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 930 B After Width: | Height: | Size: 939 B |
|
@ -1,3 +1,4 @@
|
||||||
|
import allure
|
||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
from driver.server import SquishServer
|
from driver.server import SquishServer
|
||||||
|
@ -18,3 +19,4 @@ def start_squish_server():
|
||||||
pytest.exit(err)
|
pytest.exit(err)
|
||||||
yield squish_server
|
yield squish_server
|
||||||
squish_server.stop()
|
squish_server.stop()
|
||||||
|
allure.attach.file('Squish server config', str(squish_server.config))
|
||||||
|
|
|
@ -230,6 +230,6 @@ def compare(actual: Image,
|
||||||
_logger.warning(f'VP file updated: {expected_fp}')
|
_logger.warning(f'VP file updated: {expected_fp}')
|
||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
raise AssertionError('Comparison failed')
|
raise AssertionError('Images comparison failed')
|
||||||
_logger.info(f'Screenshot comparison passed')
|
_logger.info(f'Screenshot comparison passed')
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue