1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-10-12 02:49:02 +00:00
trezor-firmware/ci/test.yml

320 lines
6.2 KiB
YAML
Raw Normal View History

image: registry.gitlab.com/satoshilabs/trezor/trezor-firmware/environment
# Core
2020-02-24 11:26:03 +00:00
core unit test:
stage: test
extends: .core_job
dependencies:
- core unix regular build
script:
- cd core
- pipenv run make test
2020-02-24 11:26:03 +00:00
core device ui test:
2019-12-09 16:01:04 +00:00
stage: test
extends: .core_job
2019-12-09 16:01:04 +00:00
dependencies:
- core unix frozen debug build
2019-12-09 16:01:04 +00:00
script:
- cd core
- pipenv run make test_emu_ui
2019-12-30 13:09:18 +00:00
- cd ../ci
- pipenv run python prepare_ui_artifacts.py
2019-12-09 16:01:04 +00:00
artifacts:
2020-02-24 11:26:03 +00:00
name: core-device-ui-test
2019-12-09 16:01:04 +00:00
paths:
- ci/ui_test_records/
- tests/ui_tests/reports/
2020-01-07 11:53:50 +00:00
- tests/junit.xml
2020-01-16 16:17:41 +00:00
- tests/trezor.log
when: always
2019-12-09 16:01:04 +00:00
expire_in: 1 week
2020-01-07 11:53:50 +00:00
reports:
junit: tests/junit.xml
2019-12-09 16:01:04 +00:00
2020-02-24 11:26:03 +00:00
core device test:
stage: test
extends: .core_job
dependencies:
- core unix frozen debug build
variables:
TREZOR_PROFILING: 1
script:
- cd core
- pipenv run make test_emu
- mv ./src/.coverage .coverage.test_emu
artifacts:
2020-02-24 11:26:03 +00:00
name: core-device-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- tests/junit.xml
- core/.coverage.*
expire_in: 1 week
when: always
reports:
junit: tests/junit.xml
2020-02-24 11:26:03 +00:00
core btconly device test:
2019-08-22 18:18:44 +00:00
stage: test
extends: .core_job
2019-08-22 18:18:44 +00:00
dependencies:
- core unix frozen btconly debug build
2019-08-22 18:18:44 +00:00
variables:
2020-01-16 14:42:41 +00:00
MICROPYTHON: "build/unix/micropython-bitcoinonly"
2019-08-22 18:18:44 +00:00
TREZOR_PYTEST_SKIP_ALTCOINS: 1
script:
- cd core
- pipenv run make test_emu
artifacts:
2020-02-24 11:26:03 +00:00
name: core-btconly-device-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- tests/junit.xml
expire_in: 1 week
when: always
reports:
junit: tests/junit.xml
2019-08-22 18:18:44 +00:00
2020-02-24 11:26:03 +00:00
core monero test:
stage: test
extends: .core_job
dependencies:
- core unix frozen debug build
variables:
TREZOR_PROFILING: 1
script:
- cd core
- pipenv run make test_emu_monero
- mv ./src/.coverage .coverage.test_emu_monero
artifacts:
2020-02-24 11:26:03 +00:00
name: core-monero-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- core/.coverage.*
expire_in: 1 week
when: always
2020-02-24 11:26:03 +00:00
core u2f test:
2019-09-14 12:47:30 +00:00
stage: test
extends: .core_job
2019-09-14 12:47:30 +00:00
dependencies:
- core unix frozen debug build
variables:
TREZOR_PROFILING: 1
2019-09-14 12:47:30 +00:00
script:
2019-09-14 12:59:11 +00:00
- make -C tests/fido_tests/u2f-tests-hid
2019-09-14 12:47:30 +00:00
- cd core
- pipenv run make test_emu_u2f
- mv ./src/.coverage .coverage.test_emu_u2f
artifacts:
2020-02-24 11:26:03 +00:00
name: core-u2f-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- core/.coverage.*
expire_in: 1 week
when: always
2019-09-14 12:47:30 +00:00
2020-02-24 11:26:03 +00:00
core fido2 test:
2019-10-18 13:35:45 +00:00
stage: test
extends: .core_job
2019-10-18 13:35:45 +00:00
dependencies:
- core unix frozen debug build
variables:
TREZOR_PROFILING: 1
2019-10-18 13:35:45 +00:00
script:
- cd core
- pipenv run make test_emu_fido2
- mv ./src/.coverage .coverage.test_emu_fido2
artifacts:
2020-02-24 11:26:03 +00:00
name: core-fido2-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- tests/junit.xml
- core/.coverage.*
expire_in: 1 week
reports:
junit: tests/junit.xml
when: always
2019-10-18 13:35:45 +00:00
2020-02-24 11:26:03 +00:00
core click test:
2019-10-25 12:03:44 +00:00
stage: test
extends: .core_job
2019-10-25 12:03:44 +00:00
dependencies:
- core unix frozen debug build
script:
- cd core
- pipenv run make test_emu_click
artifacts:
2020-02-24 11:26:03 +00:00
name: core-click-test
paths:
2020-01-16 16:17:41 +00:00
- tests/trezor.log
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
2019-10-25 12:03:44 +00:00
2020-02-24 11:26:03 +00:00
core upgrade test:
stage: test
extends: .core_job
dependencies:
- core unix frozen debug build
variables:
TREZOR_UPGRADE_TEST: "core"
script:
2019-09-12 13:42:40 +00:00
- tests/download_emulators.sh
- pipenv run pytest --junitxml=tests/junit.xml tests/upgrade_tests
artifacts:
2020-02-24 11:26:03 +00:00
name: core-upgrade-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
2020-02-24 11:26:03 +00:00
core persistence test:
2019-10-25 12:03:44 +00:00
stage: test
extends: .core_job
2019-10-25 12:03:44 +00:00
dependencies:
- core unix frozen debug build
script:
- pipenv run pytest --junitxml=tests/junit.xml tests/persistence_tests
artifacts:
2020-02-24 11:26:03 +00:00
name: core-persistence-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
2019-10-25 12:03:44 +00:00
# Crypto
crypto test:
stage: test
only:
changes:
- ci/**/*
- crypto/**/*
dependencies:
- crypto build
script:
- cd crypto
- ./tests/aestst
- ./tests/test_check
- ./tests/test_openssl 1000
- ITERS=10 pipenv run pytest --junitxml=tests/junit.xml tests
- CK_TIMEOUT_MULTIPLIER=20 valgrind -q --error-exitcode=1 ./tests/test_check
artifacts:
name: crypto-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
# Legacy
2020-02-24 11:26:03 +00:00
legacy test:
stage: test
extends: .legacy_job
dependencies:
- legacy emu regular build
variables:
EMULATOR: "1"
script:
- cd legacy
- pipenv run script/test
artifacts:
name: legacy-emu-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
2020-02-24 11:26:03 +00:00
legacy btconly test:
2019-08-22 18:18:44 +00:00
stage: test
extends: .legacy_job
2019-08-22 18:18:44 +00:00
dependencies:
- legacy emu btconly build
2019-08-22 18:18:44 +00:00
variables:
EMULATOR: "1"
EMULATOR_BINARY: "firmware/trezor-bitcoinonly.elf"
TREZOR_PYTEST_SKIP_ALTCOINS: 1
script:
- cd legacy
- pipenv run script/test
artifacts:
name: legacy-emu-btconly-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
2019-08-22 18:18:44 +00:00
2020-02-24 11:26:03 +00:00
legacy upgrade test:
stage: test
extends: .legacy_job
dependencies:
- legacy emu regular build
variables:
TREZOR_UPGRADE_TEST: "legacy"
script:
2019-09-12 13:42:40 +00:00
- tests/download_emulators.sh
- pipenv run pytest --junitxml=tests/junit.xml tests/upgrade_tests
artifacts:
name: legacy-emu-upgrade-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always
# Python
python test:
stage: test
2020-01-28 15:24:58 +00:00
dependencies: []
only:
changes:
- ci/**/*
- common/**/*
- python/**/*
script:
- cd python
- pipenv run tox
# Storage
storage test:
stage: test
only:
changes:
- ci/**/*
- storage/**/*
dependencies: []
script:
- cd storage/tests
- pipenv run make build
- pipenv run make tests_all
artifacts:
name: storage-test
paths:
- tests/junit.xml
reports:
junit: tests/junit.xml
expire_in: 1 week
when: always