当前位置:网站首页>Interface testing practical tutorial 01: interface testing environment construction
Interface testing practical tutorial 01: interface testing environment construction
2022-07-27 13:21:00 【Program yuanyuexia】
Here comes the interface testing tutorial !

Do interface test , We have to build a set of interface environment that can run locally . This time I chose an easy to build , A system suitable for learning —— Student management system .
Python install
This management system is Python It's written in code , Therefore need Python Environmental Science .

Installation is quite mindless , Install it according to the installation package and method provided by me .
Postman install
Postman Is an interface testing tool . It is also a mindless installation , Install it according to the installation package and method provided by me .

Pycharm install
Pycharm yes python Language editing tools . Anencephalic installation +3, Don't say ~

Project deployment
01 After decompressing the project , use Pycharm Open the project

02 stay Pycharm Type the command in the command line window of , Install the modules that the project depends on

pip3 install -r requirements.txt -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
03 stay Pycharm Type the command in the command line window of , Start project
python run_server.py
tips: Because avoid 2 The port to take up , I have modified the default port of the project to 8099,IP It's local 127.0.0.1( Can be in run_server.py And modify it by yourself )
Because I'm here py The default port has been modified in the file , It may be related to the interface document to be discussed later URL atypism , But it doesn't hurt ~

If you run the following error (Django Version incompatibility )
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x0000024D934BDD08>
Traceback (most recent call last):
……
File "C:\Python37\lib\site-packages\django\contrib\admin\widgets.py", line 152
'%s=%s' % (k, v) for k, v in params.items(),
^
SyntaxError: Generator expression must be parenthesizedYou need to jump to the error reporting path , Remove this comma , Then retype python run_server.py Command to start the project .

04 Read the interfaces in the project API Document or interface list , Get the interface
05 Type in the browser :IP: port /api/departments/ If you can get the data , Prove that the service was started successfully .

stay Postman Have a try , You can also get results , No problem .

above , The environment is ready . If you need a full set of projects, you can contact me , In case of problems , You can leave a comment below .
To be continued !!!
边栏推荐
- 记忆中的香河肉饼
- 完美指南|如何使用 ODBC 进行无代理 Oracle 数据库监控?
- Bank case | ZABBIX cross version upgrade guide, isn't 4.2-6.0 popular?
- Forward pre check and reverse pre check
- pg同步多张数据表至mysql 有办法简化配置吗?
- heap
- 力扣 1480. 一维数组的动态和 383. 赎金信412. Fizz Buzz
- Article reproduction: srcnn
- 粘制定位
- Poj2594 treasure exploration [bipartite graph minimum path coverage] [Floyd]
猜你喜欢

Amd adrenalin 22.7.1 driver update: double the performance of OpenGL and support Microsoft win11 22h2 system

Seata 在蚂蚁国际银行业务的落地实践

马斯克被曝绿了谷歌创始人:导致挚友二婚破裂,曾下跪求原谅

Specify the add method of HashSet

AMD Adrenalin 22.7.1 驱动更新:OpenGL 性能翻倍,支持微软 Win11 22H2 系统

分布式系统架构理论与组件

爱可可AI前沿推介(7.27)

Distributed system architecture theory and components

Why does the class annotated with @configuration generate cglib proxy?

Aike AI frontier promotion (7.27)
随机推荐
AMD Adrenalin 22.7.1 驱动更新:OpenGL 性能翻倍,支持微软 Win11 22H2 系统
7-16 daily sword finger offer II 041. Average value of sliding window
JS date and time format (year, month, day, hour, minute, second, week, quarter, time difference acquisition, date and timestamp conversion function)
Seata's landing practice in ant International Banking
Perfect guide | how to use ODBC for agent free Oracle database monitoring?
数据库HTAP能力强弱怎么看
从tidb实时同步到mysql 只能用 tidb binlog 工具吗?
[nuxt 3] (XII) project directory structure 2
multi-table query
关于 CMS 垃圾回收器,你真的懂了吗?
力扣 1480. 一维数组的动态和 383. 赎金信412. Fizz Buzz
Distributed system architecture theory and components
计算字符串最后一个单词的长度,单词以空格隔开。
插入排序,正序,倒序
Poj1548 robots [bipartite graph minimum path coverage]
Why does the class annotated with @configuration generate cglib proxy?
Xshell7 can log in to MySQL virtual machine, but not mysql
JS true / false array conversion
feign client三个客户端的自动装配
Poj2446 chessboard [maximum matching of bipartite graph]