expect/expect-filesystem
最新稳定版本:2.0.0
Composer 安装命令:
composer require expect/expect-filesystem
包简介
File system matcher for expect
README 文档
README
Basic usage
Create a configuration file of expect.
The format of the file is toml.
packages = [ "expect\\filesystem\\FileSystem" ]
Load the configuration file that you created.
use expect\Expect; use expect\configurator\FileConfigurator; $configurator = new FileConfigurator(__DIR__ . '/.expect.toml'); Expect::configure($configurator); Expect::that('log.txt')->toBeExists(); //pass Expect::that('not_found_log.txt')->toBeExists(); //failed
All of matcher
toBeExists
Expect::that($file)->toBeExists();
toBeReadable
Expect::that($file)->toBeReadable();
toBeWritable
Expect::that($file)->toBeWritable();
toBeExecutable
Expect::that($file)->toBeExecutable();
toBeDirectory
Expect::that($file)->toBeDirectory();
toBeFile
Expect::that($file)->toBeFile();
toBeMode
Expect::that($file)->toBeMode(644);
统计信息
- 总下载量: 18
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-03-30