Giter Site home page Giter Site logo

lihongbo1987 / easy-test Goto Github PK

View Code? Open in Web Editor NEW

This project forked from guojiaxing1995/easy-test

0.0 0.0 0.0 4.57 MB

自动化测试平台2.0

Shell 0.02% JavaScript 31.03% Python 13.86% CSS 9.55% HTML 0.50% Vue 43.76% Dockerfile 0.03% EJS 0.21% SCSS 1.04%

easy-test's Introduction

Easy-Test

接口自动化测试平台

python version flask version node version

项目介绍

接口自动化测试平台现在已经实现了多接口批量测试、用例管理、测试集内用例依赖关系处理、分布式异步测试执行、测试集灵活配置、测试结果多维度查看、定时任务、用例调试、mock数据管理和测试结果邮件通知等功能。

平台技术栈为 vue + python falsk 前后端分离实现,数据库使用的是mysql和mongodb,异步任务用到了rabbitmq。

源码地址:https://github.com/guojiaxing1995/easy-test

在线接口文档:https://www.showdoc.cc/easyTest

使用文档:https://blog.csdn.net/qq_36450484/article/details/107332571

部分模块展示

测试总览

测试执行

测试结果详情

mock管理

系统架构

系统架构图 浏览器请求从web前端到api服务后端,包括http请求和socketio请求。api后端服务访问mysql和mongodb数据库对数据增删改查,同时其也作为生产者将任务数据加入到rabbitmq队列中。worker作为消费者连接队列后消费队列数据执行任务,执行过程中操作数据库并请求api服务后端通过websocket连接向前端广播数据。

项目本地调试

easy-test-vue(前端)

在 easy-test-vue 目录下执行

npm install
npm run serve

指向2个后端的接口地址请查看main.js 和 Container.vue 文件中的注释。部署和本地运行这里不同。

easy-test-flask(后端)

在 easy-test-flask 目录下执行 后端服务启动

pip install -r requirements.txt
python starter.py

worker 启动

celery -A starter.celery worker -l info --pool=solo

平台docker部署

平台的所有服务、中间件和数据库都使用docker进行部署。
前端打包命令npm run build。前端vue项目使用nginx部署,default.conf配置文件在vue项目目录下,我配置了域名,部署时可以根据自己情况修改。
后端flask配置文件路径为\app\config,只需要修改静态服务地址SITE_DOMAIN(此处在nginx配置中做了转发,如果不需要则删除nginx配置文件中assets相关配置)。
worker可以根据自己的资源启动多个,修改compose文件即可。
flask工程目录下有后端服务镜像构建文件Dockerfile,后端主程序和消费端都是此镜像,启动时根据参数将容器分为主程序和消费端,1) api 作为后端主程序启动. 2)worker 作为消费者启动,默认api;vue工程目录下有前端服务镜像构建文件Dockerfile;工程目录下有docker-compose.yaml文件,该文件只需要酌情修改端口映射。镜像无需手动执行构建命令构建,服务启动会自动构建。
服务启动

docker-compose up -d

服务停止

docker-compose down

服务部署 上图红框标注处为部署成功后所有的服务。


关于系统有任何问题请联系: [email protected]

easy-test's People

Contributors

guojiaxing1995 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.