depot/third_party/nixpkgs/pkgs/development/rocm-modules/5/clr/test-rocm-smi.nix
Default email b5f92a349c Project import generated by Copybara.
GitOrigin-RevId: 7c9cc5a6e5d38010801741ac830a3f8fd667a7a0
2023-10-19 15:55:26 +02:00

23 lines
447 B
Nix

{ lib
, makeImpureTest
, clinfo
, clr
, rocm-smi
}:
makeImpureTest {
name = "rocm-smi";
testedPackage = "rocmPackages_5.clr";
nativeBuildInputs = [ clinfo rocm-smi ];
OCL_ICD_VENDORS = "${clr.icd}/etc/OpenCL/vendors";
testScript = ''
# Test fails if the number of platforms is 0
clinfo | grep -E 'Number of platforms * [1-9]'
rocm-smi | grep -A1 GPU
'';
meta = with lib; {
maintainers = teams.rocm.members;
};
}