uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
28
pkgs/development/ruby-modules/testing/assertions.nix
Normal file
28
pkgs/development/ruby-modules/testing/assertions.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{ test, lib, ...}:
|
||||
{
|
||||
equal = expected: actual:
|
||||
if actual == expected then
|
||||
(test.passed "= ${toString expected}") else
|
||||
(test.failed (
|
||||
"expected '${toString expected}'(${builtins.typeOf expected})"
|
||||
+ " != "+
|
||||
"actual '${toString actual}'(${builtins.typeOf actual})"
|
||||
));
|
||||
|
||||
beASet = actual:
|
||||
if builtins.isAttrs actual then
|
||||
(test.passed "is a set") else
|
||||
(test.failed "is not a set, was ${builtins.typeOf actual}: ${toString actual}");
|
||||
|
||||
haveKeys = expected: actual:
|
||||
if builtins.all
|
||||
(ex: builtins.any (ac: ex == ac) (builtins.attrNames actual))
|
||||
expected then
|
||||
(test.passed "has expected keys") else
|
||||
(test.failed "keys differ: expected: [${lib.concatStringsSep ";" expected}] actual: [${lib.concatStringsSep ";" (builtins.attrNames actual)}]");
|
||||
|
||||
havePrefix = expected: actual:
|
||||
if lib.hasPrefix expected actual then
|
||||
(test.passed "has prefix '${expected}'") else
|
||||
(test.failed "prefix '${expected}' not found in '${actual}'");
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue