boulzy/array-comparator
最新稳定版本:1.0.1
Composer 安装命令:
composer require boulzy/array-comparator
包简介
A library to compare arrays using matching functions
README 文档
README
Description
The boulzy/array-comparator PHP library is an extraction of the ArrayContainsComparator originally found in
imbo/behat-api-extension. It is designed to simplify array comparison
using matching functions, providing a set of tools to make array comparisons more efficient and convenient.
Installation
To install this library, you can use Composer:
composer require boulzy/array-comparator
Usage
Here's how you can use this library to compare arrays using matching functions:
require_once 'vendor/autoload.php';
$comparator = new \Boulzy\ArrayComparator\ArrayComparator();
$result = $comparator->compare($expected, $actual);
You can pass an array and/or a json string as either of the two parameters.
To see how to format the jsons / arrays, please refer to imbo/behat-api-extension documentation.
License
This project is licensed under the MIT License.
统计信息
- 总下载量: 210
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-10-23