内容简介:Laravel 7.2 发布了,此版本包含 HTTP 客户端查询字符串支持和 SMTP 邮件驱动程序的新超时配置选项。 主要新特性有: ExpectsConfirmation 测试方法 用于测试 artisan 命令的 PendingCommand 类上的 ExpectsConfi...
Laravel 7.2 发布了,此版本包含 HTTP 客户端查询字符串支持和 SMTP 邮件驱动程序的新超时配置选项。
主要新特性有:
ExpectsConfirmation 测试方法
用于测试 artisan 命令的 PendingCommand 类上的 ExpectsConfirmation() 方法:
$this
->artisan(
'foo:bar'
)
->expectsConfirmation(
'Do you want to continue?'
,
'no'
)
->assertExitCode(
1
);
SMTP 邮件驱动程序超时
SMTP 邮件驱动程序现在有了超时配置。默认值为 30 秒。如果要调整默认值,请以秒数为单位添加自定义超时配置:
'timeout' => 60 , // seconds
支持 HTTP 客户端查询字符串
这意味着可以将第二个参数传递给 Http::get()
这是一个工作原理示例:
Http::get( 'https://example.com/get' ); // URL: https://example.com/get Http::get( 'https://example.com/get?abc=123' ); // URL: https://example.com/get?abc=123 Http::get( 'https://example.com/get' , [ 'foo' => 'bar' ]); // URL: https://example.com/get?foo=bar Http::get( 'https://example.com/get' , 'foo=bar' ); // URL: https://example.com/get?foo=bar
请注意,将查询参数传递给 get() 会覆盖 URI 中的所有内容,因此使用其中一个就好。
更多详情见发布公告:
https://laravel-news.com/laravel-7-2-0
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:- NPM包(模块)发布、更新、撤销发布
- 有赞灰度发布与蓝绿发布实践
- 【重磅发布】Linkis 0.10.0 版本发布
- BeetlSQL 3.0.9 发布,Idea 插件发布
- 贝密游戏 0.7.0 发布,发布斗地主
- 【重磅发布】DataSphere Studio 0.9.0 版本发布
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
The Master Switch
Tim Wu / Knopf / 2010-11-2 / USD 27.95
In this age of an open Internet, it is easy to forget that every American information industry, beginning with the telephone, has eventually been taken captive by some ruthless monopoly or cartel. Wit......一起来看看 《The Master Switch》 这本书的介绍吧!