Code Monkey home page Code Monkey logo

dp-151's Introduction

DP-151 group project

The purpose of this repository is to provide automated test suite for OpenCart e-commerce platform.

Build Status Code style: black

Project structure

The following directories tree outlines the most important information about project structure:

.
├── README.md                 <= This file which documents the project.
├── archive                   <= pyATS reports directory (excluded from git)
├── oct                       <= a root package
│   └── tests                 <= a root package for all automated tests
│       ├── api               <= API-related tests
│       ├── deployment        <= deployment-related tests
│       └── web               <= WEB-related tests
├── suite.py                  <= a job file to run all tests
└── requirements.txt          <= Python packages for automated tests execution

Usage of automated tests

Installation

Please use Python 3.6.5 for the test execution.

Before running any command, please install required Python's dependencies with

pip install -r requirements.txt

Execution

If you need to run whole tests suite, please run

python suite.py -testbed_file testbed.yaml

If you need to run a particular test, please run

export PYTHONPATH=$(pwd):${PYTHONPATH}
python oct/tests/web/sample.py

where oct/tests/web/sample.py has to be replaced with desired test module.

Please note! If you run WEB tests, please make sure you run the chromedriver binary first.

Development of automated tests

All contributors have to follow Google Python's style guide until it conflicts with the configured tools for code quality evaluation.

Also, docstrings are optional for the project.

Type Hints are mandatory.

Installation

Please install required Python's dependencies with

pip install -r requirements-dev.txt

Code formatting

We use Black for the auto-formatting of the code. This allows supporting of common code style across all contributors and will reduce amount of lines for either merge conflicts or review.

Please run black . to reformat the code according to the projects convention.

Code assessment

We use some tools to guarantee the quality of the code.

  1. Black checks the quality of the code formatting.
  2. Pylint analyzes the code and assesses it accordingly.
  3. flake8 applies some style checks on the code.
  4. pydocstyle analyses the quality of docstrings (executed via flake8).
  5. Mypy checks static types.
  6. py.test runs unittests.

In order to run code assessment, you need to run ./code-assessment.sh command and make sure that there is no message like Code assessment is failed! Please fix errors!!!. If you face the massage, please fix all violations.

Deploy and destroy application

If you want to deploy the application to localhost, you need to run in the terminal

sudo docker-compose up

After that you can enter in the browser's search field

https://127.0.0.1 or https://localhost

and use the application. If you need to destroy application, run in the terminal

sudo docker-compose down

dp-151's People

Contributors

extsoft avatar alekseydidilov avatar goshkaegoshka avatar bambula4000 avatar alexbeatnik avatar flower1111 avatar mistergreen22 avatar

Watchers

Sergiy avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.