bats: reformat passthru.tests

Upcoming commit will add packages that use bats to passthru.tests,
which is a little more clear when this is one attrset.

Splitting this format-only change out for easier review.
This commit is contained in:
Travis A. Everett 2024-04-13 12:51:13 -05:00
parent e0f9929a69
commit bb0331762d

View File

@ -134,7 +134,8 @@ resholve.mkDerivation rec {
'';
};
passthru.tests.libraries = runCommand "${bats.name}-with-libraries-test" {
passthru.tests = {
libraries = runCommand "${bats.name}-with-libraries-test" {
testScript = ''
setup() {
bats_load_library bats-support
@ -175,7 +176,7 @@ resholve.mkDerivation rec {
touch "$out"
'';
passthru.tests.upstream = bats.unresholved.overrideAttrs (old: {
upstream = bats.unresholved.overrideAttrs (old: {
name = "${bats.name}-tests";
dontInstall = true; # just need the build directory
nativeInstallCheckInputs = [
@ -206,6 +207,7 @@ resholve.mkDerivation rec {
touch $out
'';
});
};
meta = with lib; {
homepage = "https://github.com/bats-core/bats-core";