forked from mirrors/nixpkgs
tests.buildRustCrate: add rcgen test
rcgen depends on ring, and therefore exercises support for static libraries
This commit is contained in:
parent
a6bbe3f794
commit
882741f632
|
@ -548,6 +548,10 @@ let
|
|||
};
|
||||
};
|
||||
brotliCrates = (callPackage ./brotli-crates.nix {});
|
||||
rcgenCrates = callPackage ./rcgen-crates.nix {
|
||||
# Suppress deprecation warning
|
||||
buildRustCrate = null;
|
||||
};
|
||||
tests = lib.mapAttrs (key: value: mkTest (value // lib.optionalAttrs (!value?crateName) { crateName = key; })) cases;
|
||||
in tests // rec {
|
||||
|
||||
|
@ -645,6 +649,16 @@ let
|
|||
} ''
|
||||
test -e ${pkg}/bin/brotli-decompressor && touch $out
|
||||
'';
|
||||
|
||||
rcgenTest = let
|
||||
pkg = rcgenCrates.rootCrate.build;
|
||||
in runCommand "run-rcgen-test-cmd" {
|
||||
nativeBuildInputs = [ pkg ];
|
||||
} (if stdenv.hostPlatform == stdenv.buildPlatform then ''
|
||||
${pkg}/bin/rcgen && touch $out
|
||||
'' else ''
|
||||
test -x '${pkg}/bin/rcgen' && touch $out
|
||||
'');
|
||||
};
|
||||
test = releaseTools.aggregate {
|
||||
name = "buildRustCrate-tests";
|
||||
|
|
3496
pkgs/build-support/rust/build-rust-crate/test/rcgen-crates.nix
Normal file
3496
pkgs/build-support/rust/build-rust-crate/test/rcgen-crates.nix
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue