sylogent's Introduction
0. Preconditions: 1. Install requirements virtualenv -p python3.6 venv $ ./venv/bin/pip install -r requirements.txt 2. Set environment variables 3. Run it 1. Test running example: script = c pytest -v -m "redir - single + case_1 and case_2 and not case_3": +: будут выполнены все тесты, где встречается тэг single или case_1 -: будут выполнены все тесты, где есть тэг dish и нет тэга single и все тесты где есть тэг single и нет тэга dish and: будт выполнены тесты, где присутствует тэг case_1 и case_2 and not: будут выполнены тесты, где не присутствует тег case_3 --assert=MODE control assertion debugging tools. 'plain' performs no assertion debugging. 'reinterp' reinterprets assert statements after they failed to provide assertion expression information. 'rewrite' (the default) rewrites assert statements in test modules on import to provide assert expression information. -r chars show extra test summary info as specified by chars (f)ailed, (E)error, (s)skipped, (x)failed, (X)passed (w)pytest-warnings (p)passed, (P)passed with output, (a)all except pP. --force-flaky - Авто рестарт тестов из-за ошибок тестового окружения. --max-runs=MAX_RUNS - максимальное количество попыток перезапуска одного теста, по умолчанию 1 раз @pytest.mark.xfail - пометить тест как провальный (можно) @pytest.mark.xfail(raises=RuntimeError) - задать ожидаемое исключение @pytest.mark.skipif(not os.getenv('SKIP', False), reason="Сценарий не готов") @pytest.allure.feature('<FEATURE NAME>') @pytest.allure.story('<CASE NAME>') @pytest.allure.<STATUS> - MINOR / MAJOR / CRITICAL / BLOCKER @pytest.allure.testcase('http://example.com') @pytest.allure.issue('http://jira.edgex-team.ru/browse/<ITEM>') 3. Environment variables: 0. Python https://docs.python.org/3.5/using/cmdline.html $PYTHONUNBUFFERED $PYTHONDONTWRITEBYTECODE $PYTHONTHREADDEBUG 2. Logs: $LOGGING_LEVEL - уровень логирования (CRITICAL, ERROR, WARNING, INFO, SUBDEBUG, DEBUG, NOTSET) $LOGGING_LEVEL_TO_CONSOLE - уровень логирования (CRITICAL, ERROR, WARNING, INFO, SUBDEBUG, DEBUG, NOTSET) 3. Selenium $USE_LOCALHOST=1 $CHROME_DRIVER_PATH=/usr/local/bin/chromedriver $SELENIUM_HUB
sylogent's People
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.