博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
codeception 调出sendPost等函数
阅读量:4538 次
发布时间:2019-06-08

本文共 681 字,大约阅读时间需要 2 分钟。

在写codeception functional test 时测试中如果包含post请求,那么我们就需要调用函数sendPost。

默认情况下的functional tester中是不包含该函数的,需要enable这写函数,具体方法如下:

在functional.suite.yml文件中:

class_name: FunctionalTestermodules:    enabled:      - Filesystem      - Yii2      - Db      - REST//添加REST模块    config:        Yii2:            configFile: 'codeception/config/functional.php'        Db:            dsn: 'mysql:host=localhost;dbname=test_db'            user: 'test_user'            password: 'test_password'            dump: 'codeception/_data/dump.sql'            populate: true            cleanup: false        REST:            url: 'http://site.test/api'//添加REST模块

 

转载于:https://www.cnblogs.com/wlemory/p/4766310.html

你可能感兴趣的文章
LPC1788系统时钟初始化
查看>>
channel vs mutex
查看>>
页面布局(--FlowLayout,--BorderLayout,--GridLayout)
查看>>
实验吧--web--你真的会php吗
查看>>
vue组件化学习第二天
查看>>
网络枚举工具推荐
查看>>
003LeetCode--LongestSubstring
查看>>
quarzt(官方)---给自己看的文档(SchedulerListeners)-8
查看>>
Linux-慕课网学习笔记-3-1命令格式
查看>>
AJAX入门介绍
查看>>
[算法竞赛入门]第一章_算法概述
查看>>
SQL反模式笔记3——主键规范
查看>>
简单粗暴,微生物生态研究中常用数据库简介--转载
查看>>
Oracle -操作数据库
查看>>
c - 给分数分级别
查看>>
chrome 调试
查看>>
luoguP2774 方格取数问题
查看>>
tcp/ip协议各层的理解与
查看>>
python中的setdefault()方法
查看>>
转 VSFTP用户权限管控
查看>>