Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/soh335/test-deep-pairbag
https://github.com/soh335/test-deep-pairbag
Last synced: 14 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/soh335/test-deep-pairbag
- Owner: soh335
- License: other
- Created: 2013-07-20T06:36:07.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2013-07-20T06:49:30.000Z (over 11 years ago)
- Last Synced: 2024-10-11T21:11:50.447Z (about 1 month ago)
- Language: Perl
- Size: 125 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: Changes
- License: LICENSE
Awesome Lists containing this project
README
# NAME
Test::Deep::PairBag - compare arrayref as hashref stored mutiple value per key by Test::Deep
# SYNOPSIS
use Test::Deep;
use Test::Deep::PairBag;cmp_deeply(
[ foo => 1, bar => 2, foo => 3 ],
pair_bag(foo => 1, foo => 3, bar => 2)
);# DESCRIPTION
Test::Deep::PairBag compare arrayref as hashref stored mutiple value per key by [Test::Deep](http://search.cpan.org/perldoc?Test::Deep).
In Test::Deep::PairBag, got array and expected array are took out two elements and wraped as arrayref.
So, `[foo => 1, bar => 2, foo => 3]` is translated to `[ [foo => 1], [bar => 2], [foo => 3] ]`.
And, comparing them by `Test::Deep::bag`.# Functions
- pair\_bag($expected)
_$expected_ should be array reference.
# LICENSE
Copyright (C) soh335.
This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself.# AUTHOR
soh335