Skip to content

bddwithTim/healthcare-ffm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FFM - Healthcare plans extraction

This repository utilizes pytest framework for automation testing.

Development

Prerequisites:

poetry is a tool to handle dependency installation as well as building and packaging of Python packages. It only needs one file to do all of that: the new, standardized pyproject.toml.

In other words, poetry uses pyproject.toml to replace setup.py, requirements.txt, setup.cfg, MANIFEST.in and the newly added Pipfile.

Poetry and virtual environment setup

After cloning this github repository, prepare your development environment like so:

  • Set up a Python virtual environment by navigating to PyCharm's Project Python Interpreter and create a new .venv environment.

    Add Python Interpreter

  • Click the OK button and close the Settings modal as the packages will not be populated at first. Open the Python Interpreter once again and add the poetry package. Click the Specify version checkbox and from its drop-down selection, select the version 1.1.12 and click Install Package. Once installed, close the Project Settings altogether.

    Poetry Package

  • Open a cmd/bash terminal Alt+F12 in PyCharm and execute:

    poetry install

Test Execution

  • Executing parallel tests. pytest -n <num> where <num> is the number of test instances.

    pytest -n 3
  • Executing tests which match the given substring expression. pytest -k expression. An expression is a python evaluatable expression where all names are substring-matched against test names and their parent classes.

    • executes all tests under the python file healthcare_ffm_test.py
    pytest -k healthcare_ffm_test.py
    • executes the test function named test_healthcare_basic_flow
    pytest -k test_healthcare_basic_flow
  • Executing all tests under a directory.

    pytest ./tests

Alternatively, if the commands on the terminal doesn't work due to Optum's restrictions then utilize Pycharm's Run/Debug Configuration and add the sample arguments above inside the Additional Arguments text field.

pytest_run_debug_configurations

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages